busybox/networking/udhcp
Andrey Mazo 87e216294a udhcpc: don't exit after backgrounding on -n -b
Currently, running "udhcpc -n -b" causes udhcpc to go to background and
then exit after some time unless a lease is obtained.

It's not very useful to do so
as the calling process doesn't know
if the lease was obtained or not anyway.

The code actually tries to favor "-b" over "-n",
but doesn't clear "-n" flag while clearing "-b" after backgrounding.

So, clear "-n" flag after going into background.
This effectively makes "-b" override "-n" completely
and "-n -b" behave the same as "-b".

This allows to override default "-n" option, passed to udhcpc by ifupdown,
without recompiling busybox.

URL: https://bugs.busybox.net/11691

Signed-off-by: Andrey Mazo <ahippo@yandex.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2019-02-27 08:27:47 +01:00
..
arpping.c
common.c udhcpc: when decoding DHCP_SUBNET, ensure it is 4 bytes long 2019-01-07 15:33:42 +01:00
common.h Update examples/udhcp/udhcpd.conf 2019-01-15 13:19:01 +01:00
Config.src config: add size information for three more applets 2018-12-28 13:37:44 +01:00
d6_common.h udhcpc6: add DHCPv6 boot options 2018-05-14 10:46:00 +02:00
d6_dhcpc.c udhcpc: don't exit after backgrounding on -n -b 2019-02-27 08:27:47 +01:00
d6_packet.c udhcpc[6]: make log2 messages for chaddr field indented like the rest 2017-09-29 18:02:01 +02:00
d6_socket.c ioctl(SIOCGIFINDEX) does not require clearing of entire ifr 2018-03-27 23:55:43 +02:00
dhcpc.c udhcpc: don't exit after backgrounding on -n -b 2019-02-27 08:27:47 +01:00
dhcpc.h udhcpc6: make -O OPT work 2017-06-28 19:18:17 +02:00
dhcpd.c randomconfig fixes 2018-12-27 18:03:20 +01:00
dhcpd.h
dhcprelay.c dhcprelay: code shrink 2018-01-08 10:14:17 +01:00
domain_codec.c whitespace and comment format fixes, no code changes 2017-10-05 14:40:24 +02:00
dumpleases.c getopt32: remove opt_complementary 2017-08-08 21:55:02 +02:00
Kbuild.src fix breakage found by mass one-applet builds 2016-12-23 02:42:26 +01:00
packet.c udhcpc: remove code which requires server ID to be on local network 2018-06-21 17:38:14 +02:00
signalpipe.c udhcpd: fix "not dying on SIGTERM" 2018-03-10 19:34:39 +01:00
socket.c udhcpc: downgrade "MAC X:X:X:X:X:X" message to log2 level 2017-07-24 13:37:38 +02:00