From: Denys Vlasenko Date: Sat, 21 Nov 2009 14:44:56 +0000 (+0100) Subject: ping: use |=, not =, when combine option bit mask X-Git-Tag: 1_16_0~217 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=85164fa06eac734dd853b7e08c1762ada06e9a2c;p=oweals%2Fbusybox.git ping: use |=, not =, when combine option bit mask Signed-off-by: Denys Vlasenko --- diff --git a/networking/ping.c b/networking/ping.c index 0ca41b9fa..c7b6cbe9a 100644 --- a/networking/ping.c +++ b/networking/ping.c @@ -726,7 +726,7 @@ static int common_ping_main(int opt, char **argv) /* exactly one argument needed; -v and -q don't mix; -c NUM, -w NUM, -W NUM */ opt_complementary = "=1:q--v:v--q:c+:w+:W+"; - opt = getopt32(argv, OPT_STRING, &pingcount, &str_s, &deadline, &timeout, &str_I); + opt |= getopt32(argv, OPT_STRING, &pingcount, &str_s, &deadline, &timeout, &str_I); if (opt & OPT_s) datalen = xatou16(str_s); // -s if (opt & OPT_I) { // -I