Author: vangyzen Date: Fri Oct 2 14:21:07 2015 New Revision: 288497 URL: https://svnweb.freebsd.org/changeset/base/288497
Log: MFC r281785 Always send log(9) messages to the message buffer. It is truer to the semantics of logging for messages to *always* go to the message buffer, where they can eventually be collected and, in fact, be put into a log file. This restores the behavior prior to r70239, which seems to have changed it inadvertently. Submitted by: Eric Badger <e...@badgerio.us> Obtained from: Dell Inc. Modified: stable/10/share/man/man9/printf.9 stable/10/sys/kern/subr_prf.c Directory Properties: stable/10/ (props changed) Modified: stable/10/share/man/man9/printf.9 ============================================================================== --- stable/10/share/man/man9/printf.9 Fri Oct 2 14:16:37 2015 (r288496) +++ stable/10/share/man/man9/printf.9 Fri Oct 2 14:21:07 2015 (r288497) @@ -67,7 +67,8 @@ The .Fn log function sends the message to the kernel logging facility, using the log level as indicated by -.Fa pri . +.Fa pri , +and to the console if no process is yet reading the log. .Pp Each of these related functions use the .Fa fmt Modified: stable/10/sys/kern/subr_prf.c ============================================================================== --- stable/10/sys/kern/subr_prf.c Fri Oct 2 14:16:37 2015 (r288496) +++ stable/10/sys/kern/subr_prf.c Fri Oct 2 14:21:07 2015 (r288497) @@ -305,7 +305,7 @@ log(int level, const char *fmt, ...) va_list ap; va_start(ap, fmt); - (void)_vprintf(level, log_open ? TOLOG : TOCONS, fmt, ap); + (void)_vprintf(level, log_open ? TOLOG : TOCONS | TOLOG, fmt, ap); va_end(ap); msgbuftrigger = 1; _______________________________________________ svn-src-stable-10@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10 To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"