This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Time to add strlcpy/strlcat FINALLY
- From: "Michael Kerrisk (man-pages)" <mtk dot lists at gmail dot com>
- To: Mike Frysinger <vapier at gentoo dot org>, libc-alpha at sourceware dot org
- Cc: mtk dot manpages at gmail dot com, William Park <opengeometry at yahoo dot ca>
- Date: Fri, 15 Aug 2014 12:37:19 +0200
- Subject: Re: Time to add strlcpy/strlcat FINALLY
- Authentication-results: sourceware.org; auth=none
- References: <E1XHgtz-0001zg-Ct at rmm6prod02 dot runbox dot com> <53EC0C42 dot 9080002 at cs dot ucla dot edu> <20140814030204 dot GA13982 at node1 dot localdomain> <4433106 dot 9VQ5DDSLdU at vapier>
- Reply-to: mtk dot manpages at gmail dot com
On 08/14/2014 03:01 PM, Mike Frysinger wrote:
> On Wed 13 Aug 2014 23:02:05 William Park wrote:
>> What are the alternatives, though? Everyone criticizes 'strcpy' but
>> it's included in glibc. But, 'strlcpy' is excluded on the ground that
>> it's not sufficiently better. Seems to me, someone has sensitive toes.
>
> err, no, your example makes no sense. one of these things is in the standards
> documents while the other is not. get strlcpy into POSIX :P.
These functions were apparently explicitly rejected by POSIX.
For those new to this well worn debate, my article here provides some
background: https://lwn.net/Articles/507319/
Cheers,
Michael