When the remote log feature is active, running syslogd would not log locally by default. Without this patch, the only way to activate local logging was to use the '-L' argument.
tested by doing : busybox syslogd -n -f /dev/null -O - And then by running : busybox logger foo bar The syslogd process is expected to output a message like : <date> user.notice <youruser> foo bar Signed-off-by: Nicholas Niro <[email protected]> --- sysklogd/syslogd.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sysklogd/syslogd.c b/sysklogd/syslogd.c index 7558051f0..075d08f99 100644 --- a/sysklogd/syslogd.c +++ b/sysklogd/syslogd.c @@ -1044,8 +1044,10 @@ static int NOINLINE syslogd_init(char **argv) G.shm_size = xatoul_range(opt_C, 4, INT_MAX/1024) * 1024; #endif /* If they have not specified remote logging, then log locally */ - if (ENABLE_FEATURE_REMOTE_LOG && !(opts & OPT_remotelog)) // -R + if (ENABLE_FEATURE_REMOTE_LOG && !(opts & OPT_remotelog)) { // -R option_mask32 |= OPT_locallog; + opts |= OPT_locallog; + } #if ENABLE_FEATURE_SYSLOGD_CFG parse_syslogdcfg(opt_f); #endif -- 2.39.5 _______________________________________________ busybox mailing list [email protected] https://lists.busybox.net/mailman/listinfo/busybox
