mirror of
https://github.com/GnoConsortium/gno.git
synced 2024-11-15 00:05:20 +00:00
7199e83868
Initial checkin for sprintmt(3) and vsprintmt(3) documentation. syslog.3: Add descriptions of syslogmt(3) and vsyslogmt(3), which are thread- safe variants with more limited format specifiers. progname.3: Added description of the "__progname" variable. This in effect exposes the cache value used by __prognameGS(). It was necessary for the proper operation of the thread-safe syslog routines.
41 lines
1015 B
Groff
41 lines
1015 B
Groff
.\" Man page by Devin Reade.
|
|
.\"
|
|
.\" $Id: progname.3,v 1.2 1998/10/25 17:15:51 gdr-ftp Exp $
|
|
.\"
|
|
.TH "__PROGNAMEGS" 3 "21 January 1997" GNO "Library Routines"
|
|
.SH NAME
|
|
.BR __prognameGS
|
|
\- get the program name
|
|
.SH SYNOPSIS
|
|
#include <gno/gno.h>
|
|
.sp 1
|
|
char *\fB__progname\fR;
|
|
.br
|
|
char *\fB__prognameGS\fR (void);
|
|
.SH DESCRIPTION
|
|
.BR __progname
|
|
points to a NULL-terminated string which is the base name of the
|
|
executing program. It is initially the string '(unknown)', but is
|
|
set to the proper value upon the first call to
|
|
.BR __prognameGS .
|
|
.LP
|
|
.BR __prognameGS
|
|
sets the string
|
|
.BR __progname
|
|
to its proper value by using the result of the GS/OS
|
|
.BR GetNameGS
|
|
system call. If for some reason that system call fails, the value of
|
|
.BR __progname
|
|
is left unchanged. On success, the value is cached, so subsequent calls to
|
|
.BR __prognameGS
|
|
merely reference
|
|
.BR __progname .
|
|
.SH RETURN VALUE
|
|
.BR __prognameGS
|
|
always returns the value of
|
|
.BR __progname .
|
|
.SH SEE ALSO
|
|
.BR err (3),
|
|
.br
|
|
The \fIGS/OS Reference Manual\fR.
|