strcpy_s, strlcpy, and strncpy and checking for overflow

Yuhong Bao yuhongbao_386@hotmail.com
Sat May 5 17:17:00 GMT 2007


But one of the arguments is that programmers should be concerned about the 
effect of truncation. strlcpy make it easier than strncpy to check for 
truncation too, and strcpy_s (part of VC2005 libraries) refuse to copy the 
string at all if the string is going to be truncated. You must use strncpy_s 
with _TRUNCATE in the count parameter.

_________________________________________________________________
Check Out Our List Of Trendy Restaurants. You'll Eat It Up! 
http://local.live.com/?mkt=en-ca/?v=2&cid=A6D6BDB4586E357F!378



More information about the Libc-alpha mailing list