diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2020-05-26 23:28:41 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2020-05-26 23:28:41 +0000 |
commit | b42f25da7c53bfb8302b1db8defc37ad76e34e05 (patch) | |
tree | 4c8e7ab3b251debba87b1467e3c07e4a13c3d682 | |
parent | a615c79fa6fb789018b76a329c171b727cc1ce4b (diff) |
Nuke a superflous local array in release_lease().
-rw-r--r-- | sbin/dhclient/dhclient.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sbin/dhclient/dhclient.c b/sbin/dhclient/dhclient.c index f5f754b37fc..91be80d18e4 100644 --- a/sbin/dhclient/dhclient.c +++ b/sbin/dhclient/dhclient.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dhclient.c,v 1.673 2020/05/20 19:13:34 krw Exp $ */ +/* $OpenBSD: dhclient.c,v 1.674 2020/05/26 23:28:40 krw Exp $ */ /* * Copyright 2004 Henning Brauer <henning@openbsd.org> @@ -2759,7 +2759,6 @@ tick_msg(const char *preamble, int success, time_t start) void release_lease(struct interface_info *ifi) { - char destbuf[INET_ADDRSTRLEN]; char ifabuf[INET_ADDRSTRLEN]; struct option_data *opt; @@ -2772,7 +2771,6 @@ release_lease(struct interface_info *ifi) ifi->destination.s_addr = *(in_addr_t *)opt->data; else ifi->destination.s_addr = INADDR_BROADCAST; - strlcpy(destbuf, inet_ntoa(ifi->destination), sizeof(destbuf)); ifi->xid = arc4random(); make_release(ifi, ifi->active); @@ -2799,7 +2797,8 @@ release_lease(struct interface_info *ifi) free(ifi->unwind_info); ifi->unwind_info = NULL; - log_warnx("%s: %s RELEASED to %s", log_procname, ifabuf, destbuf); + log_warnx("%s: %s RELEASED to %s", log_procname, ifabuf, + inet_ntoa(ifi->destination)); } void |