News for hackers. Stuff that matters.
Re:Strcpycat by byuu on Saturday January 21, 2012 @04:34AM (#3493145)
Thanks, I will make the necessary corrections shortly.

The strncat() behavior is quite confusing. I can understand expecting the buffer to already be null-padded and skipping that step, but always null-terminating the result seems to go against strncpy()'s expected behavior. It also looks mildly dangerous, as the NUL-write can be one after the size given.

Re:Strcpycat by caf on Saturday January 21, 2012 @05:38AM (#3493259)
It's not confusing when you realise that strncat() is not a concatenating analogue of strncpy(). It's just a version of strcat() that accepts an upper bound on the number of characters copied.