mirror of
https://gitlab.isc.org/isc-projects/dhcp
synced 2025-08-31 22:35:25 +00:00
Properly initialize sockaddr to 0.
Submitted by: Jun-ichiro itojun Hagino <itojun@iijlab.net> RT #: 3040
This commit is contained in:
@@ -44,7 +44,7 @@
|
|||||||
|
|
||||||
#ifndef lint
|
#ifndef lint
|
||||||
static char copyright[] =
|
static char copyright[] =
|
||||||
"$Id: icmp.c,v 1.31 2001/06/27 00:29:49 mellon Exp $ Copyright (c) 1996-2001 The Internet Software Consortium. All rights reserved.\n";
|
"$Id: icmp.c,v 1.32 2002/06/09 22:16:34 murray Exp $ Copyright (c) 1996-2001 The Internet Software Consortium. All rights reserved.\n";
|
||||||
#endif /* not lint */
|
#endif /* not lint */
|
||||||
|
|
||||||
#include "dhcpd.h"
|
#include "dhcpd.h"
|
||||||
@@ -163,6 +163,7 @@ int icmp_echorequest (addr)
|
|||||||
if (!icmp_state)
|
if (!icmp_state)
|
||||||
log_fatal ("ICMP protocol used before initialization.");
|
log_fatal ("ICMP protocol used before initialization.");
|
||||||
|
|
||||||
|
memset (&to, 0, sizeof(to));
|
||||||
#ifdef HAVE_SA_LEN
|
#ifdef HAVE_SA_LEN
|
||||||
to.sin_len = sizeof to;
|
to.sin_len = sizeof to;
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user