Hi Andrew,

* Andrew Duane <[email protected]>, 20111108 16:22:
> Checking the return code of strlcpy won't say if the entire string fit
> (exactly) correctly, or if it was truncated.

It seems they do:

RETURN VALUES
     The strlcpy() and strlcat() functions return the total length of the
     string they tried to create.  For strlcpy() that means the length of src.
     For strlcat() that means the initial length of dst plus the length of
     src.  While this may seem somewhat confusing, it was done to make trunca‐
     tion detection simple.

-- 
 Ed Schouten <[email protected]>
 WWW: http://80386.nl/

Attachment: pgp3k0xKTMyC1.pgp
Description: PGP signature

Reply via email to