- (djm) Use VIS_SAFE on logged strings rather than default strnvis

encoding (which encodes many more characters)
This commit is contained in:
Damien Miller 2003-05-23 18:43:40 +10:00
parent 1340ec297b
commit d419bdae77
2 changed files with 6 additions and 2 deletions

View File

@ -1,3 +1,7 @@
20030523
- (djm) Use VIS_SAFE on logged strings rather than default strnvis
encoding (which encodes many more characters)
20030520
- (djm) OpenBSD CVS Sync
- deraadt@cvs.openbsd.org 2003/05/18 23:22:01
@ -1585,4 +1589,4 @@
save auth method before monitor_reset_key_state(); bugzilla bug #284;
ok provos@
$Id: ChangeLog,v 1.2744 2003/05/19 23:24:42 djm Exp $
$Id: ChangeLog,v 1.2745 2003/05/23 08:43:40 djm Exp $

2
log.c
View File

@ -391,7 +391,7 @@ do_log(LogLevel level, const char *fmt, va_list args)
vsnprintf(msgbuf, sizeof(msgbuf), fmt, args);
}
/* Escape magic chars in output. */
strnvis(fmtbuf, msgbuf, sizeof(fmtbuf), VIS_OCTAL);
strnvis(fmtbuf, msgbuf, sizeof(fmtbuf), VIS_SAFE|VIS_OCTAL);
if (log_on_stderr) {
snprintf(fmtbuf, sizeof fmtbuf, "%s\r\n", msgbuf);