This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Replace strncpy with memccpy to fix -Wstringop-truncation.
- From: Andreas Schwab <schwab at suse dot de>
- To: Stefan Liebler <stli at linux dot vnet dot ibm dot com>
- Cc: libc-alpha at sourceware dot org
- Date: Thu, 05 Apr 2018 18:14:26 +0200
- Subject: Re: [PATCH] Replace strncpy with memccpy to fix -Wstringop-truncation.
- References: <20180323010729.41457-1-raj.khem@gmail.com> <alpine.DEB.2.20.1803230115280.6153@digraph.polyomino.org.uk> <CAMKF1sqVBx3_8sK=BuH_HRFDLTQqtT9M8t=eSDpOVRyJRAnOkw@mail.gmail.com> <796d9b52-7270-69d4-cfc2-1ce05b6ebbf1@linux.vnet.ibm.com>
On Apr 05 2018, Stefan Liebler <stli@linux.vnet.ibm.com> wrote:
> Why do we need the strncpy at all?
> if (len == 0 && ...)
That's obviously a typo.
Andreas.
--
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."