PERFORCE change 132441 for review
John Birrell
jb at FreeBSD.org
Thu Jan 3 15:35:32 PST 2008
http://perforce.freebsd.org/chv.cgi?CH=132441
Change 132441 by jb at jb_freebsd1 on 2008/01/03 23:34:46
Add a hack to report if an attempt is being made to free a NULL pointer.
I am so sick of seeing the DTrace kernel module do that before I've got
it re-ported.
Affected files ...
.. //depot/projects/dtrace/src/sys/compat/opensolaris/kern/opensolaris_kmem.c#4 edit
Differences ...
==== //depot/projects/dtrace/src/sys/compat/opensolaris/kern/opensolaris_kmem.c#4 (text+ko) ====
@@ -95,6 +95,10 @@
zfs_kmem_free(void *buf, size_t size __unused)
{
#ifdef KMEM_DEBUG
+ if (buf == NULL) {
+ printf("%s: attempt to free NULL\n",__func__);
+ return;
+ }
struct kmem_item *i;
buf = (u_char *)buf - sizeof(struct kmem_item);
More information about the p4-projects
mailing list