diff options
Diffstat (limited to 'networking/udhcp')
-rw-r--r-- | networking/udhcp/d6_dhcpc.c | 7 | ||||
-rw-r--r-- | networking/udhcp/dhcpc.c | 10 | ||||
-rw-r--r-- | networking/udhcp/dhcpd.c | 7 | ||||
-rw-r--r-- | networking/udhcp/dumpleases.c | 8 |
4 files changed, 20 insertions, 12 deletions
diff --git a/networking/udhcp/d6_dhcpc.c b/networking/udhcp/d6_dhcpc.c index 84969aa..849ca13 100644 --- a/networking/udhcp/d6_dhcpc.c +++ b/networking/udhcp/d6_dhcpc.c @@ -1101,13 +1101,14 @@ int udhcpc6_main(int argc UNUSED_PARAM, char **argv) client_config.script = CONFIG_UDHCPC_DEFAULT_SCRIPT; /* Parse command line */ - /* O,x: list; -T,-t,-A take numeric param */ - IF_UDHCP_VERBOSE(opt_complementary = "vv";) - opt = getopt32long(argv, "i:np:qRr:s:T:+t:+SA:+O:*ox:*f" + opt = getopt32long(argv, "^" + /* O,x: list; -T,-t,-A take numeric param */ + "i:np:qRr:s:T:+t:+SA:+O:*ox:*f" USE_FOR_MMU("b") ///IF_FEATURE_UDHCPC_ARPING("a") IF_FEATURE_UDHCP_PORT("P:") "v" + "\0" IF_UDHCP_VERBOSE("vv") /* -v is a counter */ , udhcpc6_longopts , &client_config.interface, &client_config.pidfile, &str_r /* i,p */ , &client_config.script /* s */ diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c index 5f87f85..55e0400 100644 --- a/networking/udhcp/dhcpc.c +++ b/networking/udhcp/dhcpc.c @@ -1295,16 +1295,18 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv) str_V = "udhcp "BB_VER; /* Parse command line */ - /* O,x: list; -T,-t,-A take numeric param */ - IF_UDHCP_VERBOSE(opt_complementary = "vv";) - opt = getopt32long(argv, "CV:H:h:F:i:np:qRr:s:T:+t:+SA:+O:*ox:*fB" + opt = getopt32long(argv, "^" + /* O,x: list; -T,-t,-A take numeric param */ + "CV:H:h:F:i:np:qRr:s:T:+t:+SA:+O:*ox:*fB" USE_FOR_MMU("b") IF_FEATURE_UDHCPC_ARPING("a::") IF_FEATURE_UDHCP_PORT("P:") "v" + "\0" IF_UDHCP_VERBOSE("vv") /* -v is a counter */ , udhcpc_longopts , &str_V, &str_h, &str_h, &str_F - , &client_config.interface, &client_config.pidfile, &str_r /* i,p */ + , &client_config.interface, &client_config.pidfile /* i,p */ + , &str_r /* r */ , &client_config.script /* s */ , &discover_timeout, &discover_retries, &tryagain_timeout /* T,t,A */ , &list_O diff --git a/networking/udhcp/dhcpd.c b/networking/udhcp/dhcpd.c index 3a5fc2d..05ddc86 100644 --- a/networking/udhcp/dhcpd.c +++ b/networking/udhcp/dhcpd.c @@ -814,11 +814,12 @@ int udhcpd_main(int argc UNUSED_PARAM, char **argv) IF_FEATURE_UDHCP_PORT(SERVER_PORT = 67;) IF_FEATURE_UDHCP_PORT(CLIENT_PORT = 68;) + opt = getopt32(argv, "^" + "fSI:va:"IF_FEATURE_UDHCP_PORT("P:") + "\0" #if defined CONFIG_UDHCP_DEBUG && CONFIG_UDHCP_DEBUG >= 1 - opt_complementary = "vv"; + "vv" #endif - opt = getopt32(argv, "fSI:va:" - IF_FEATURE_UDHCP_PORT("P:") , &str_I , &str_a IF_FEATURE_UDHCP_PORT(, &str_P) diff --git a/networking/udhcp/dumpleases.c b/networking/udhcp/dumpleases.c index fb1860f..70d2d14 100644 --- a/networking/udhcp/dumpleases.c +++ b/networking/udhcp/dumpleases.c @@ -54,8 +54,12 @@ int dumpleases_main(int argc UNUSED_PARAM, char **argv) #endif init_unicode(); - opt_complementary = "=0:a--r:r--a"; - opt = getopt32long(argv, "arf:d", dumpleases_longopts, &file); + opt = getopt32long(argv, "^" + "arf:d" + "\0" "=0:a--r:r--a", + dumpleases_longopts, + &file + ); fd = xopen(file, O_RDONLY); |