Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Jan 2007 16:03:43 GMT
From:      Todd Miller <millert@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 113344 for review
Message-ID:  <200701221603.l0MG3hee027061@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=113344

Change 113344 by millert@millert_macbook on 2007/01/22 16:02:51

	sebsd_label_destroy() may be passed a NULL pointer if one
	of the per-policy label init routines fails.  In this case
	the framework has to clean up an allocations that did succeed
	but it is not smart enough to only clean up the ones up
	until the point of failure.

Affected files ...

.. //depot/projects/trustedbsd/sedarwin8/policies/sedarwin/sedarwin/sebsd.c#69 edit

Differences ...

==== //depot/projects/trustedbsd/sedarwin8/policies/sedarwin/sedarwin/sebsd.c#69 (text+ko) ====

@@ -550,7 +550,8 @@
 sebsd_label_destroy(struct label *label)
 {
 
-	mac_zfree(sebsd_label_zone, SLOT(label));
+	if (SLOT(label)  != NULL)
+		mac_zfree(sebsd_label_zone, SLOT(label));
 	SLOT(label) = NULL;
 }
 



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