dropbear: cherry-pick upstream patches
[openwrt/staging/robimarko.git] / package / network / services / dropbear / patches / 019-Allow-inetd-with-non-syslog.patch
1 From 383cc8c97a9420aad9cf93d88e77ec636b183a9d Mon Sep 17 00:00:00 2001
2 From: Matt Johnston <matt@ucc.asn.au>
3 Date: Mon, 11 Dec 2023 23:18:09 +0800
4 Subject: Allow inetd with non-syslog
5
6 An inetd-alike should be able to distinguish stdout and stderr, so
7 it's a valid configuration.
8
9 Fixes #218 on github
10 ---
11 svr-runopts.c | 12 ------------
12 1 file changed, 12 deletions(-)
13
14 --- a/svr-runopts.c
15 +++ b/svr-runopts.c
16 @@ -443,18 +443,6 @@ void svr_getopts(int argc, char ** argv)
17 }
18 }
19
20 -#if INETD_MODE
21 - if (svr_opts.inetdmode && (
22 - opts.usingsyslog == 0
23 -#if DEBUG_TRACE
24 - || debug_trace
25 -#endif
26 - )) {
27 - /* log output goes to stderr which would get sent over the inetd network socket */
28 - dropbear_exit("Dropbear inetd mode is incompatible with debug -v or non-syslog");
29 - }
30 -#endif
31 -
32 if (svr_opts.multiauthmethod && svr_opts.noauthpass) {
33 dropbear_exit("-t and -s are incompatible");
34 }