From 200f8951348878fb138eeb9116475a907a9ba8eb Mon Sep 17 00:00:00 2001 From: Arseny Maslennikov Date: Mon, 11 Dec 2017 19:09:07 +0300 Subject: [PATCH] dhcp.c: Fix potentially destructive typo in perform_dhcp() --- dhcp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dhcp.c b/dhcp.c index 35c8fe7..be6805f 100644 --- a/dhcp.c +++ b/dhcp.c @@ -552,7 +552,7 @@ enum return_type perform_dhcp(struct interface_info * intf) messageType = DHCP_TYPE_DISCOVER; add_vendor_code(&breq, DHCP_OPTION_TYPE, 1, &messageType); - memset(&client_addr.sin_addr, 0, sizeof(&client_addr.sin_addr)); + memset(&client_addr.sin_addr, 0, sizeof(client_addr.sin_addr)); client_addr.sin_family = AF_INET; client_addr.sin_port = htons(BOOTP_CLIENT_PORT); /* bootp client */ -- 2.10.4