3 ms·
I'm guessing the string was part of a larger struct, and they wanted to clear the entire struct with a single memset. It's a somewhat common pattern in C, but
by phire 3y ago
I'm guessing the string was part of a larger struct, and they wanted to clear the entire struct with a single memset.
It's a somewhat common pattern in C, but requires care.
- deleted 3y ago[deleted]
- rewmie 3y ago> It's a somewhat common pattern in C (...) C++ isn't C, though.