diff options
author | Eric Andersen <andersen@codepoet.org> | 2003-12-30 10:57:16 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2003-12-30 10:57:16 +0000 |
commit | 6373c2b14188d31a3e4a3d7eb917b0479d56f373 (patch) | |
tree | 997ff466ee42617dc0250194764734f6eb9a3081 /libc/stdlib/malloc-standard | |
parent | 5c62002cc864b92f9c1517449e197c55adb9ff44 (diff) |
Fix the manditory typo in my last minute untested fix.
-Erik
Diffstat (limited to 'libc/stdlib/malloc-standard')
-rw-r--r-- | libc/stdlib/malloc-standard/calloc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libc/stdlib/malloc-standard/calloc.c b/libc/stdlib/malloc-standard/calloc.c index cff0adab8..a67dad738 100644 --- a/libc/stdlib/malloc-standard/calloc.c +++ b/libc/stdlib/malloc-standard/calloc.c @@ -29,7 +29,7 @@ void* calloc(size_t n_elements, size_t elem_size) /* guard vs integer overflow, but allow nmemb * to fall through and call malloc(0) */ - size=lsize * nmemb; + size = n_elements * elem_size; if (n_elements && elem_size != (size / n_elements)) { __set_errno(ENOMEM); return NULL; |