dhcpv4: rename valid_until_cb()
authorDavid Härdeman <[email protected]>
Wed, 24 Sep 2025 12:31:58 +0000 (14:31 +0200)
committerÁlvaro Fernández Rojas <[email protected]>
Fri, 3 Oct 2025 10:53:04 +0000 (12:53 +0200)
Renaming valid_until_cb() to dhcpv4_valid_until_cb() is more consistent with
the other function names and is helpful if the function ever shows up in a
stack trace.

Signed-off-by: David Härdeman <[email protected]>
Link: https://github.com/openwrt/odhcpd/pull/264
Signed-off-by: Álvaro Fernández Rojas <[email protected]>
src/dhcpv4.c

index 385faf6924a051ffcf2a4cac6ca50142666a1d53..e2c978a44cc393cc5cd5fe7f4c68dcfe04618e56 100644 (file)
@@ -1218,7 +1218,7 @@ static void dhcpv4_netevent_cb(unsigned long event, struct netevent_handler_info
        }
 }
 
-static void valid_until_cb(struct uloop_timeout *event)
+static void dhcpv4_valid_until_cb(struct uloop_timeout *event)
 {
        struct interface *iface;
        time_t now = odhcpd_time();
@@ -1241,7 +1241,7 @@ static void valid_until_cb(struct uloop_timeout *event)
 int dhcpv4_init(void)
 {
        static struct netevent_handler dhcpv4_netevent_handler = { .cb = dhcpv4_netevent_cb };
-       static struct uloop_timeout valid_until_timeout = { .cb = valid_until_cb };
+       static struct uloop_timeout valid_until_timeout = { .cb = dhcpv4_valid_until_cb };
 
        uloop_timeout_set(&valid_until_timeout, 1000);
        netlink_add_netevent_handler(&dhcpv4_netevent_handler);