3 ms·
What is false? I'm not talking about the source string not being terminated when it's too long. That's obvious and there are plenty posts about it in this thre
by tobiasu 13y ago
What is false? I'm not talking about the source string not being terminated when it's too long. That's obvious and there are plenty posts about it in this thread.
Not sure what you want to say with the example code. Maybe swap it for strncpy and strlcpy and see whether that matches your expectations?
- dllthomas 13y agoYeah, my bad, had meant to use strncpy. My contention had been that it only zeroes the first following character (if that). On closer reading of the man page, it is in fact clear.