summaryrefslogtreecommitdiffstats
path: root/monitor_mm.c
diff options
context:
space:
mode:
Diffstat (limited to 'monitor_mm.c')
-rw-r--r--monitor_mm.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/monitor_mm.c b/monitor_mm.c
index faf9f3dc..ee7bad4b 100644
--- a/monitor_mm.c
+++ b/monitor_mm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: monitor_mm.c,v 1.16 2009/06/22 05:39:28 dtucker Exp $ */
+/* $OpenBSD: monitor_mm.c,v 1.17 2013/05/17 00:13:13 djm Exp $ */
/*
* Copyright 2002 Niels Provos <provos@citi.umich.edu>
* All rights reserved.
@@ -35,6 +35,7 @@
#include <errno.h>
#include <stdarg.h>
+#include <stdlib.h>
#include <string.h>
#include "xmalloc.h"
@@ -124,7 +125,7 @@ mm_freelist(struct mm_master *mmalloc, struct mmtree *head)
next = RB_NEXT(mmtree, head, mms);
RB_REMOVE(mmtree, head, mms);
if (mmalloc == NULL)
- xfree(mms);
+ free(mms);
else
mm_free(mmalloc, mms);
}
@@ -147,7 +148,7 @@ mm_destroy(struct mm_master *mm)
__func__);
#endif
if (mm->mmalloc == NULL)
- xfree(mm);
+ free(mm);
else
mm_free(mm->mmalloc, mm);
}
@@ -198,7 +199,7 @@ mm_malloc(struct mm_master *mm, size_t size)
if (mms->size == 0) {
RB_REMOVE(mmtree, &mm->rb_free, mms);
if (mm->mmalloc == NULL)
- xfree(mms);
+ free(mms);
else
mm_free(mm->mmalloc, mms);
}
@@ -254,7 +255,7 @@ mm_free(struct mm_master *mm, void *address)
prev->size += mms->size;
RB_REMOVE(mmtree, &mm->rb_free, mms);
if (mm->mmalloc == NULL)
- xfree(mms);
+ free(mms);
else
mm_free(mm->mmalloc, mms);
} else
@@ -278,7 +279,7 @@ mm_free(struct mm_master *mm, void *address)
RB_REMOVE(mmtree, &mm->rb_free, mms);
if (mm->mmalloc == NULL)
- xfree(mms);
+ free(mms);
else
mm_free(mm->mmalloc, mms);
}