SYNOPSIS
#include <syslog.h>
syslog(int priority, char *message, ...);
DESCRIPTION
The
In the event log file, the date, time, user name, computer name, event ID, source, event type, and event category are penned to the log message.
PARAMETERS
- priority
-
Is encoded within the NuTCRACKER Platform to reflect the Microsoft Win32 event type. The UNIX priority is translated as follows:
- LOG_EMERG
-
An error event. This priority logs the event as a Win32 error event and displays the alert box containing the message on the screen. The process is terminated when the user selects OK in the dialog box.
- LOG_ALERT, LOG_CRIT, LOG_ERR
-
An error event. This priority logs the event as a Win32 error event and returns control to the calling process.
- LOG_WARNING
-
A warning event. This priority logs the event as a Win32 warning event and returns control to the calling process.
- LOG_NOTICE, LOG_INFO, LOG_DEBUG
-
An information event. This priority logs the event as a Win32 information event and returns control to the calling process.
- message
-
Is used with the following arguments to generate the message body in the same manner as if these were arguments to
printf() , except that occurrences of %m in the format string pointed to by the message argument are replaced by the error messages string associated with the current value of errno. A trailing newline character is added if needed. - ...
-
Represents
printf() -style substitution arguments for message.
RETURN VALUES
None.
CONFORMANCE
UNIX 98.
MULTITHREAD SAFETY LEVEL
MT-Safe.
PORTING ISSUES
On Windows NT/2000/XP/2003/Vista, messages are logged in the system's Application Event log.
The ident string passed to
AVAILABILITY
MKS Toolkit for Professional Developers
MKS Toolkit for Enterprise Developers
MKS Toolkit for Enterprise Developers 64-Bit Edition
SEE ALSO
- Functions:
closelog() ,openlog() ,setlogmask() ,vsyslog()
MKS Toolkit 9.2 Documentation Build 16.