Hacker News new | past | comments | ask | show | jobs | submit login

> But calloc lives inside the memory allocator, so it knows whether the memory it's returning is fresh from the operating system, and if it is then it skips calling memset. And this is why calloc has to be built into the standard library, and you can't fake it yourself.

Err...mmap(2)?




You can't fake it yourself from within the C stdlib is what the author means.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: