svn commit: r190493 - head/lib/libc/db/hash
Xin LI
delphij at FreeBSD.org
Fri Mar 27 23:40:49 PDT 2009
Author: delphij
Date: Sat Mar 28 06:40:48 2009
New Revision: 190493
URL: http://svn.freebsd.org/changeset/base/190493
Log:
Avoid NULL deference which causes DEBUG1 to crash, not to print useful
information.
Obtained from: OpenBSD
Modified:
head/lib/libc/db/hash/hash_buf.c
Modified: head/lib/libc/db/hash/hash_buf.c
==============================================================================
--- head/lib/libc/db/hash/hash_buf.c Sat Mar 28 06:38:31 2009 (r190492)
+++ head/lib/libc/db/hash/hash_buf.c Sat Mar 28 06:40:48 2009 (r190493)
@@ -282,7 +282,7 @@ newbuf(HTAB *hashp, u_int32_t addr, BUFH
*/
#ifdef DEBUG1
(void)fprintf(stderr, "NEWBUF2: %d->ovfl was %d is now %d\n",
- prev_bp->addr, (prev_bp->ovfl ? bp->ovfl->addr : 0),
+ prev_bp->addr, (prev_bp->ovfl ? prev_bp->ovfl->addr : 0),
(bp ? bp->addr : 0));
#endif
prev_bp->ovfl = bp;
More information about the svn-src-all
mailing list