aboutsummaryrefslogtreecommitdiff
path: root/winsup/cygwin/cygheap.cc
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/cygheap.cc')
-rw-r--r--winsup/cygwin/cygheap.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/cygheap.cc b/winsup/cygwin/cygheap.cc
index e583c1e..c6503c4 100644
--- a/winsup/cygwin/cygheap.cc
+++ b/winsup/cygwin/cygheap.cc
@@ -260,7 +260,7 @@ ccalloc (cygheap_types x, DWORD n, DWORD size)
MALLOC_CHECK;
c = (cygheap_entry *) _cmalloc (sizeof_cygheap (n * size));
if (c)
- memset (c->data, 0, size);
+ memset (c->data, 0, n * size);
if (!c)
system_printf ("ccalloc returned NULL");
return creturn (x, c, n);