udhcpc: small simplification
authorDenys Vlasenko <vda.linux@googlemail.com>
Sun, 19 Jul 2009 02:35:16 +0000 (04:35 +0200)
committerDenys Vlasenko <vda.linux@googlemail.com>
Sun, 19 Jul 2009 02:35:16 +0000 (04:35 +0200)
function                                             old     new   delta
udhcpc_main                                         2401    2398      -3

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
networking/udhcp/dhcpc.c

index 636061818199d382fb8d6ab34060407e7a31eb49..fbb645749809e3b921dfae713b6eb378c25b45e4 100644 (file)
@@ -628,10 +628,7 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv)
                                                inet_ntoa(temp_addr), (unsigned)lease_seconds);
                                }
                                requested_ip = packet.yiaddr;
-                               udhcp_run_script(&packet,
-                                       ((state >= RENEWING && state <= RENEW_REQUESTED)
-                                       ? "renew" : "bound")
-                               );
+                               udhcp_run_script(&packet, state == REQUESTING ? "bound" : "renew");
 
                                state = BOUND;
                                change_listen_mode(LISTEN_NONE);