summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libc/stdlib/malloc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/libc/stdlib/malloc.c b/src/lib/libc/stdlib/malloc.c
index 36d2d717db..84d22507c0 100644
--- a/src/lib/libc/stdlib/malloc.c
+++ b/src/lib/libc/stdlib/malloc.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: malloc.c,v 1.177 2015/12/09 02:45:23 tedu Exp $ */ 1/* $OpenBSD: malloc.c,v 1.178 2015/12/30 06:01:18 tedu Exp $ */
2/* 2/*
3 * Copyright (c) 2008, 2010, 2011 Otto Moerbeek <otto@drijf.net> 3 * Copyright (c) 2008, 2010, 2011 Otto Moerbeek <otto@drijf.net>
4 * Copyright (c) 2012 Matthew Dempsky <matthew@openbsd.org> 4 * Copyright (c) 2012 Matthew Dempsky <matthew@openbsd.org>
@@ -1225,8 +1225,10 @@ validate_junk(void *p) {
1225 if (p == NULL) 1225 if (p == NULL)
1226 return; 1226 return;
1227 r = find(pool, p); 1227 r = find(pool, p);
1228 if (r == NULL) 1228 if (r == NULL) {
1229 wrterror("bogus pointer in validate_junk", p); 1229 wrterror("bogus pointer in validate_junk", p);
1230 return;
1231 }
1230 REALSIZE(sz, r); 1232 REALSIZE(sz, r);
1231 if (sz > 0 && sz <= MALLOC_MAXCHUNK) 1233 if (sz > 0 && sz <= MALLOC_MAXCHUNK)
1232 sz -= mopts.malloc_canaries; 1234 sz -= mopts.malloc_canaries;