Created
November 10, 2014 07:37
-
-
Save hduffddybz/7b2b460bf1806a173e26 to your computer and use it in GitHub Desktop.
Usage of syslogd
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <syslog.h> | |
int main() | |
{ | |
setlogmask(LOG_UPTO(LOG_NOTICE)); | |
openlog("testlog", LOG_CONS | LOG_PID | LOG_NDELAY, LOG_LOCAL0); | |
syslog(LOG_NOTICE, "LOG NOTICE"); | |
syslog(LOG_INFO, "LOG INFO"); | |
closelog(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment