Comment

Comment by bpineau

"We now do this consistently: a = malloc(n * sizeof(a));"

Isn't calloc(3) the safer paradigm (protecting against integer overflows, in case n sizeof > SIZE_MAX) recommanded for this case ? (besides the memory zeroing).

parent bpineau 11 years ago

No comments yet

Be the first to share your thoughts.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton