svn commit: r297222 - head/sys/kern

Bryan Drewery bdrewery at FreeBSD.org
Thu Mar 24 03:08:40 UTC 2016


Author: bdrewery
Date: Thu Mar 24 03:08:39 2016
New Revision: 297222
URL: https://svnweb.freebsd.org/changeset/base/297222

Log:
  Fix M_RTABLE memory leak from r274118 (11/2014).
  
  Replace free(M_RTABLE) with rn_detachhead() to match rn_inithead().
  
  This would trigger when reloading NFS exports and was similar to
  problems with pf reload [1].
  
  PR:		194078 [1]
  Sponsored by:	EMC / Isilon Storage Division

Modified:
  head/sys/kern/vfs_export.c

Modified: head/sys/kern/vfs_export.c
==============================================================================
--- head/sys/kern/vfs_export.c	Thu Mar 24 02:15:23 2016	(r297221)
+++ head/sys/kern/vfs_export.c	Thu Mar 24 03:08:39 2016	(r297222)
@@ -259,7 +259,7 @@ vfs_free_addrlist_af(struct radix_node_h
 	(*rnh->rnh_walktree)(&rnh->rh, vfs_free_netcred, &rnh->rh);
 	RADIX_NODE_HEAD_UNLOCK(rnh);
 	RADIX_NODE_HEAD_DESTROY(rnh);
-	free(rnh, M_RTABLE);
+	rn_detachhead((void **)prnh);
 	prnh = NULL;
 }
 


More information about the svn-src-head mailing list