From 66659ff1ad6831b0ea7425fa6ecd8a8687523658 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Wed, 6 Nov 2013 16:20:21 +0100 Subject: Update to FreeBSD 9.2 --- freebsd/sbin/dhclient/clparse.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'freebsd/sbin/dhclient/clparse.c') diff --git a/freebsd/sbin/dhclient/clparse.c b/freebsd/sbin/dhclient/clparse.c index 7fb278dd..b52bc473 100644 --- a/freebsd/sbin/dhclient/clparse.c +++ b/freebsd/sbin/dhclient/clparse.c @@ -875,6 +875,7 @@ parse_string_list(FILE *cfile, struct string_list **lp, int multiple) { int token; char *val; + size_t valsize; struct string_list *cur, *tmp; /* Find the last medium in the media list. */ @@ -892,10 +893,11 @@ parse_string_list(FILE *cfile, struct string_list **lp, int multiple) return; } - tmp = new_string_list(strlen(val) + 1); + valsize = strlen(val) + 1; + tmp = new_string_list(valsize); if (tmp == NULL) error("no memory for string list entry."); - strlcpy(tmp->string, val, strlen(val) + 1); + memcpy(tmp->string, val, valsize); tmp->next = NULL; /* Store this medium at the end of the media list. */ -- cgit v1.2.3