summaryrefslogtreecommitdiff
path: root/usr.bin/ssh/monitor_wrap.c
diff options
context:
space:
mode:
authorMarkus Friedl <markus@cvs.openbsd.org>2021-04-15 16:24:32 +0000
committerMarkus Friedl <markus@cvs.openbsd.org>2021-04-15 16:24:32 +0000
commita2bcb0e0d4948a2eb07dbaf2a5cbd560c26dd07e (patch)
tree91f4ad8d383198499c62523f0324b38eb9b14278 /usr.bin/ssh/monitor_wrap.c
parente526118e8c0c7fc4919c666a8046a02116acba11 (diff)
do not pass file/func to monitor; noted by Ilja van Sprundel; ok djm@
Diffstat (limited to 'usr.bin/ssh/monitor_wrap.c')
-rw-r--r--usr.bin/ssh/monitor_wrap.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/usr.bin/ssh/monitor_wrap.c b/usr.bin/ssh/monitor_wrap.c
index 890925005f1..3a7145aa6f4 100644
--- a/usr.bin/ssh/monitor_wrap.c
+++ b/usr.bin/ssh/monitor_wrap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: monitor_wrap.c,v 1.122 2020/11/27 00:37:10 djm Exp $ */
+/* $OpenBSD: monitor_wrap.c,v 1.123 2021/04/15 16:24:31 markus Exp $ */
/*
* Copyright 2002 Niels Provos <provos@citi.umich.edu>
* Copyright 2002 Markus Friedl <markus@openbsd.org>
@@ -78,8 +78,7 @@ extern struct sshbuf *loginmsg;
extern ServerOptions options;
void
-mm_log_handler(const char *file, const char *func, int line,
- LogLevel level, const char *msg, void *ctx)
+mm_log_handler(LogLevel level, int forced, const char *msg, void *ctx)
{
struct sshbuf *log_msg;
struct monitor *mon = (struct monitor *)ctx;
@@ -93,10 +92,8 @@ mm_log_handler(const char *file, const char *func, int line,
fatal_f("sshbuf_new failed");
if ((r = sshbuf_put_u32(log_msg, 0)) != 0 || /* length; filled below */
- (r = sshbuf_put_cstring(log_msg, file)) != 0 ||
- (r = sshbuf_put_cstring(log_msg, func)) != 0 ||
- (r = sshbuf_put_u32(log_msg, (u_int)line)) != 0 ||
(r = sshbuf_put_u32(log_msg, level)) != 0 ||
+ (r = sshbuf_put_u32(log_msg, forced)) != 0 ||
(r = sshbuf_put_cstring(log_msg, msg)) != 0)
fatal_fr(r, "assemble");
if ((len = sshbuf_len(log_msg)) < 4 || len > 0xffffffff)