1PMSETPROGNAME(3)           Library Functions Manual           PMSETPROGNAME(3)
2
3
4

NAME

6       pmSetProgname, pmGetProgname - application name services
7

C SYNOPSIS

9       #include <pcp/pmapi.h>
10
11       void pmSetProgname(const char *program);
12       char *pmGetProgname(void);
13
14       cc ... -lpcp
15

DESCRIPTION

17       Within  the Performance Co-Pilot (PCP) run-time libraries the name of a
18       running application is maintained to be used in  error  and  diagnostic
19       messages.
20
21       The default application name is pcp.
22
23       pmSetProgname  may be used to set the application name to program after
24       stripping any leading components that begin with  the  filesystem  path
25       name separator (``/'' for Unix-like systems).
26
27       It  is  the  callers  responsibility to ensure the memory pointed to by
28       program remains available for the life of the application.   Typically,
29       the  value passed as program for a C program would be argv[0].  If pro‐
30       gram is NULL, the default application name is restored.
31
32       pmGetProgname may be used to return the current application name.
33

SEE ALSO

35       PMAPI(3).
36
37
38
39Performance Co-Pilot                  PCP                     PMSETPROGNAME(3)
Impressum