Name
syslog
Synopsis
bool syslog(intpriority, stringmessage)
Sends an error message to the system logging facility. On Unix
systems, this is syslog(3); on
Windows NT, the messages are logged in the NT Event Log. The message
is logged with the given priority, which is one of the following
(listed in decreasing order of priority):
| Error has caused the system to be unstable |
| Error notes a situation that requires immediate action |
| Error is a critical condition |
| Error is a general error condition |
| Error message is a warning |
| Error message is a normal, but significant, condition |
| Error is an informational message that requires no action |
| Error is for debugging only |
If message contains the characters
%m, they are replaced with the
current error message, if any is set. Returns true if the logging succeeded and false if a failure occurred.
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access