This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: strcpy_s, strlcpy, and strncpy and checking for overflow


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



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]