git: dhclient - Remove cur_time global.

Antonio Huete Jimenez tuxillo at
Sat Aug 9 09:40:31 PDT 2014

commit 3c279f6e4ed072b70dbe273d2748999f478ae6bd
Author: Antonio Huete Jimenez <tuxillo at>
Date:   Fri Aug 1 20:19:04 2014 +0200

    dhclient - Remove cur_time global.
    - Junk global cur_time, and use time(NULL) or local variables where
      time is checked multiple times. Add a set_timeout_interval() function
      to allow setting a timeout based on an interval from current time.
    - Fixes issues with initial startup where the global cur_time was
      always old and caused initial DHCPDISCOVER or DHCPREQUEST packets
      to be sent multiple times. And probably other timeout related
    Taken-from: OpenBSD

Summary of changes:
 sbin/dhclient/clparse.c  |  4 ++--
 sbin/dhclient/dhclient.c | 42 ++++++++++++++++++++++++++----------------
 sbin/dhclient/dhcpd.h    |  4 ++--
 sbin/dhclient/dispatch.c | 14 +++++++++-----
 4 files changed, 39 insertions(+), 25 deletions(-)

DragonFly BSD source repository

More information about the Commits mailing list