[Linux] Syslogd로 출력하는 코드

TechNote Forum Forums Forum [Linux] Syslogd로 출력하는 코드

This topic contains 0 replies, has 1 voice, and was last updated by  technote 2 years ago.

Viewing 1 post (of 1 total)
  • Author
  • #126


    #include <syslog.h> vsyslog(syslog_priority(level), fmt, ap); static int syslog_priority(int level) { switch (level) { case MSG_MSGDUMP: case MSG_DEBUG: return LOG_DEBUG; case MSG_INFO: return LOG_NOTICE; case MSG_WARNING: return LOG_WARNING; case MSG_ERROR: return LOG_ERR; } return LOG_INFO; } enum { MSG_EXCESSIVE, MSG_MSGDUMP, MSG_DEBUG, MSG_INFO, MSG_WARNING, MSG_ERROR };

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.