From b30c1637bd3a4c420ba75bb6ace45ba704e1f286 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Wed, 20 Feb 2008 17:30:00 +0000 Subject: One last tweak on debugging code. svn:r13621 --- src/common/container.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common/container.h b/src/common/container.h index 058f22ef5..0f17fa999 100644 --- a/src/common/container.h +++ b/src/common/container.h @@ -348,7 +348,8 @@ bitarray_expand(bitarray_t *ba, ptr = tor_realloc(ba, sz_new*sizeof(unsigned int)); /* This memset does nothing to the older excess bytes. But they were * already set to 0 by bitarry_init_zero. */ - memset(ptr+sz_old, 0, (sz_new-sz_old)*sizeof(unsigned int)); + memset(ptr+sz_old*sizeof(unsigned int), 0, + (sz_new-sz_old)*sizeof(unsigned int)); return (bitarray_t*) ptr; } /** Free the bit array ba. */ -- cgit v1.2.3