From: Roy Marples Date: Thu, 25 Feb 2010 09:22:30 +0000 (+0000) Subject: Fix a crash when server sends more than one of the same option. X-Git-Tag: v5.2.0~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=42bee7f18505d6c3718e9970f785e47aab670ebc;p=thirdparty%2Fdhcpcd.git Fix a crash when server sends more than one of the same option. Thanks to Xia Weizhong. --- diff --git a/dhcp.c b/dhcp.c index c036c00f..df9f1f43 100644 --- a/dhcp.c +++ b/dhcp.c @@ -362,7 +362,7 @@ exit: *len = bl; if (bp) { memcpy(bp, op, ol); - return (const uint8_t *)&opt_buffer; + return (const uint8_t *)opt_buffer; } if (op) return op;