c_wrtlog - Write an informational message to a log file

SYNTAX

FUNCTION c_wrtlog(logfile, key, code, text)

     char    *logfile;
     char    *key;   
     char    *code; 
     char    *text;

PARAMETERS

logfile (char *, input)

The host name of the log file to write to.

key (char *, input)

Key to be written to the log file. The key identifies what the program was working on (for example, the name of the image being processed).

code (char *, input)

Operation code of the message. The code indicates the event that just occurred within a program.

text (char *, input)

Descriptive text, a fuller explanation of the event that was logged.

DESCRIPTION

The c_wrtlog() routine is used to write a message to the named log file. The log file is locked, the message is written to the file, and the file is unlocked. The message is in the format:

key	date	time	code	text
The following is an example of what might be written to a log file:

namerica  05/28/93  08:17:55  bwtrans  Completed the browse transfer

RETURN VALUE

c_wrtlog() returns

     E_SUCC (0)  --> successful write of log message
     E_FAIL (-1) --> log file could not be opened or appended to