Showing posts with label C. Show all posts
Showing posts with label C. Show all posts

Tuesday, October 15, 2013

strncpy and null termination

strncpy does not put \n if the length fits its destination array. Needs to assure the string is null terminated in some way.

Ref:
http://www.thinkage.ca/english/gcos/expl/c/lib/strncp.html