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

NAME

6       pmNoMem - report out of memory conditions
7

C SYNOPSIS

9       #include <pcp/pmapi.h>
10
11       void pmNoMem(const char *where, size_t size, int fatal);
12
13       cc ... -lpcp
14

DESCRIPTION

16       pmNoMem  is  a  convenience method that may be used when malloc(3) or a
17       related memory allocation service fails.
18
19       A standard message is emitted using pmNotifyErr(3) with where used as a
20       message prefix and the failing allocation size is also reported.
21
22       If fatal is zero (and PM_RECOV_ERR is zero), pmNoMem returns (the allo‐
23       cation failure is assumed to be recoverable by the caller),  else  (and
24       PM_FATAL_ERR  is  a  good  value to use in this case) exit(2) is called
25       with an argument of 1.
26

SEE ALSO

28       exit(2), malloc(3), PMAPI(3) and pmNotifyErr(3).
29
30
31
32Performance Co-Pilot                  PCP                           PMNOMEM(3)
Impressum