linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* blind conversion strncpy -> strlcpy is harmful
@ 2003-07-01 10:33 Andries.Brouwer
  0 siblings, 0 replies; only message in thread
From: Andries.Brouwer @ 2003-07-01 10:33 UTC (permalink / raw)
  To: linux-kernel

I notice that people have been replacing strncpy by strlcpy,
introducing bugs in the process.

It is not true that strlcpy is guaranteed to be better than
strncpy. Indeed, strlcpy cannot handle character arrays that
are not necessarily 0-terminated.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-07-01 10:19 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-01 10:33 blind conversion strncpy -> strlcpy is harmful Andries.Brouwer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).