Re: [Freeciv-Dev] patch: zstrncpy() (PR#112)
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Alex Zepeda wrote:
> On Wed, 25 Aug 1999, David Pfitzner wrote:
> > * zstrncpy():
> > *
> > * Like strncpy(), but with some features to make it easier to
> > * keep strings null-terminated. In particular, always writes
> > * a terminating null, including when input is longer than n.
>
> Have you seen strlcpy and strlcat?
Thanks, strlcpy looks like just what I was wanting. :-)
(The only real difference looks like they made a slightly
different decision on the return value if src is too long.)
-- David
|
|