Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src



Module Name:    src
Committed By:   roy
Date:           Wed Mar 22 17:52:37 UTC 2017

Modified Files:
        src/lib/libc/gen: syslog.3 xsyslog.c
        src/sys/sys: syslog.h

Log Message:
openlog(3): add LOG_PTRIM and LOG_NLOG log options.

syslog(3) is the one stop method of logging system events and diagnostics.
When debugging a daemon in the foreground on a terminal, each line is
prefixed with tag[pid]: which is very repetative and can take up valuable
screen estate.
LOG_PTRIM solves this by removing this prefix from stderr output.

There is also the case where the debugging could involve a dry-run and
syslog(3) calls would pollute the system log with incorrect data.
LOG_NLOG solves this by not writing the the system log, but allowing
LOG_PERROR to operate as before.

Initially discussed here:
https://mail-index.netbsd.org/tech-userlevel/2016/10/06/msg010330.html


To generate a diff of this commit:
cvs rdiff -u -r1.30 -r1.31 src/lib/libc/gen/syslog.3
cvs rdiff -u -r1.2 -r1.3 src/lib/libc/gen/xsyslog.c
cvs rdiff -u -r1.40 -r1.41 src/sys/sys/syslog.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index