ZCOM C I/F Library Routines

ZCOMLOG (3X)

PARAMETERS

error Error code to be logged (unsigned int). The error code is displayed as a 5-digit unsigned value (ranges from 00000 to 99999) in the error message log file.

msgno ID number of the message to be logged (signed int).

narg Number of arguments to be logged with the message (positive int).

desc Argument descriptor used to describe the “type” of the argument which follows. The values of this parameter may be one of the following:

ZCOM_AT_CHAR

- char

ZCOM_AT_UCHAR

- unsigned char

ZCOM_AT_SINT

- short int

ZCOM_AT_USINT

- unsigned short int

ZCOM_AT_INT

- int

ZCOM_AT_STR

- char *

ZCOM_AT_ERRNO

- int (UNIX error code, usually errno)

 

UNIX error string will be logged

ZCOM_AT_ZERROR

- int (ZCOM error code)

 

ZCOM error string will be logged

ZCOM_AT_ZSTAT

- int (ZCOM status code)

 

ZCOM status string will be logged

ZCOM_AT_XSTAT

- int (ZCOM X.25 status code)

 

ZCOM X.25 status string will be logged

arg Argument value to insert into the message to be logged. Note that the argument’s type must match the type specified in the desc parameter. Each argument will be substituted into the message text string using printf.

RETURN VALUE

Routine zcomlog has no return value.

NOTES

1. The ZMLOG program retrieves the unique message test using the

 

logging program name and message number. By default, the message

 

tests of all log messages are retrieved from the message file

 

default.msg in /opt/acc/msg. If the environment variable “LANG” is

 

defined, the message text is retrieved from the message file

 

$LANG.msg instead. In case it does not exist, the default.msg file is

 

used. This allows support for multiple message file in different

 

languages.

 

2. Before calling this routine, zcomlname(3X) should be called to set up

 

the logging program name for all subsequent log records.

Chapter 4

185