Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Jan 2016 19:43:26 +0000 (UTC)
From:      "Bjoern A. Zeeb" <bz@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r294592 - projects/vnet/sys/netinet
Message-ID:  <201601221943.u0MJhQ87099653@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bz
Date: Fri Jan 22 19:43:26 2016
New Revision: 294592
URL: https://svnweb.freebsd.org/changeset/base/294592

Log:
  Fix build and avoid a double-free in the VIMAGE case.
  
  Sponsored by:	The FreeBSD Foundation

Modified:
  projects/vnet/sys/netinet/ip_divert.c

Modified: projects/vnet/sys/netinet/ip_divert.c
==============================================================================
--- projects/vnet/sys/netinet/ip_divert.c	Fri Jan 22 19:06:43 2016	(r294591)
+++ projects/vnet/sys/netinet/ip_divert.c	Fri Jan 22 19:43:26 2016	(r294592)
@@ -811,7 +811,9 @@ div_modevent(module_t mod, int type, voi
 		ip_divert_ptr = NULL;
 		err = pf_proto_unregister(PF_INET, IPPROTO_DIVERT, SOCK_RAW);
 		INP_INFO_WUNLOCK(&V_divcbinfo);
-		div_destroy();
+#ifndef VIMAGE
+		div_destroy(NULL);
+#endif
 		EVENTHANDLER_DEREGISTER(maxsockets_change, ip_divert_event_tag);
 		break;
 	default:



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