1ADDSEVERITY(3)             Linux Programmer's Manual            ADDSEVERITY(3)
2
3
4

NAME

6       addseverity - introduce new severity classes
7

SYNOPSIS

9       #define _SVID_SOURCE
10       #include <fmtmsg.h>
11
12       int addseverity(int severity, const char *s);
13
14

DESCRIPTION

16       This function allows the introduction of new severity classes which can
17       be addressed by the severity parameter of the  fmtmsg(3)  function.  By
18       default  that  latter  function  only  knows  how to print messages for
19       severity 0-4 (with strings (none), HALT, ERROR,  WARNING,  INFO).  This
20       call  attaches the given string s to the given value severity.  If s is
21       NULL, the severity class with the numeric value  severity  is  removed.
22       It  is  not possible to overwrite or remove one of the default severity
23       classes. The severity value must be nonnegative.
24

RETURN VALUE

26       Upon success, the value MM_OK is returned. Upon error, the return value
27       is MM_NOTOK.  Possible errors include: out of memory, attempt to remove
28       a nonexistent or default severity class.
29

NOTE

31       New severity classes can also be added by setting the environment vari‐
32       able SEV_LEVEL.
33

CONFORMING TO

35       This function is not specified in the X/Open Portability Guide although
36       the fmtmsg() function is.  It is available on System V systems.
37

SEE ALSO

39       fmtmsg(3), feature_test_macros(7)
40
41
42
43gnu                               2002-08-07                    ADDSEVERITY(3)
Impressum