Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> The handling of endptr in DYN_ARR_RESIZE seems to be incorrect. If I have an array with 2 elements and capacity of 3 and I DYN_ARR_RESIZE it to 5, I now have an array with 5 elements, 3 of which are garbage values.

Why do you say this is wrong? That's exactly what I would expect.



> Why do you say this is wrong?

Exposing uninitialized memory as valid values tends to be a really bad idea.




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

Search: