Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 28 Apr 2017 09:17:16 +0000 (UTC)
From:      Maxim Konovalov <maxim@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r317546 - head/usr.sbin/tcpdrop
Message-ID:  <201704280917.v3S9HGLU064733@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: maxim
Date: Fri Apr 28 09:17:16 2017
New Revision: 317546
URL: https://svnweb.freebsd.org/changeset/base/317546

Log:
  o Clean the whole array of IPv4 addresses not just a local part.
  
  PR:		218923
  Submitted by:	Daniel McRobb

Modified:
  head/usr.sbin/tcpdrop/tcpdrop.c

Modified: head/usr.sbin/tcpdrop/tcpdrop.c
==============================================================================
--- head/usr.sbin/tcpdrop/tcpdrop.c	Fri Apr 28 05:43:27 2017	(r317545)
+++ head/usr.sbin/tcpdrop/tcpdrop.c	Fri Apr 28 09:17:16 2017	(r317546)
@@ -321,7 +321,7 @@ tcpdropconn(const struct in_conninfo *in
 		    sizeof inc->inc6_faddr);
 		foreign = (struct sockaddr *)&sin6[TCPDROP_FOREIGN];
 	} else {
-		memset(&sin4[TCPDROP_LOCAL], 0, sizeof sin4[TCPDROP_LOCAL]);
+		memset(sin4, 0, sizeof sin4);
 
 		sin4[TCPDROP_LOCAL].sin_len = sizeof sin4[TCPDROP_LOCAL];
 		sin4[TCPDROP_LOCAL].sin_family = AF_INET;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201704280917.v3S9HGLU064733>