2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-08-31 14:25:15 +00:00

Log warning() at SUDO_DEBUG_WARN not SUDO_DEBUG_ERROR.

Log the function, file and line number in the debug log for warning()
and error().
This commit is contained in:
Todd C. Miller
2012-04-05 12:37:15 -04:00
parent 2fe41248ac
commit 2c84bd4d08
6 changed files with 181 additions and 112 deletions

View File

@@ -3725,8 +3725,8 @@ sudoers_trace_print(const char *msg)
/* XXX - assumes a final newline */
if (strchr(msg, '\n') != NULL)
{
sudo_debug_printf2(SUDO_DEBUG_PARSER|SUDO_DEBUG_DEBUG, "%s:%d %s",
sudoers, sudolineno, lbuf.buf);
sudo_debug_printf2(NULL, NULL, 0, SUDO_DEBUG_PARSER|SUDO_DEBUG_DEBUG,
"%s:%d %s", sudoers, sudolineno, lbuf.buf);
lbuf.len = 0;
}
return 0;