From: "H.J. Lu" <hjl.tools@gmail.com>
To: Florian Weimer <fweimer@redhat.com>
Cc: libc-alpha@sourceware.org
Subject: Re: [PATCH v2 0/3] strlcpy and related functions
Date: Thu, 20 Apr 2023 09:19:47 -0700 [thread overview]
Message-ID: <CAMe9rOoZN7hGVC2So=JkU7Ym3ZSOr2Y2NjYx=-5adDo04EUiZA@mail.gmail.com> (raw)
In-Reply-To: <cover.1681993374.git.fweimer@redhat.com>
On Thu, Apr 20, 2023 at 5:28 AM Florian Weimer via Libc-alpha
<libc-alpha@sourceware.org> wrote:
>
> I split this repost somewhat differently, with the manual updates in a
> separate commit, so that I can give proper attribution to Paul's work.
>
> I went through the discussion again and wasn't sure if there was
> anything regarding the actual implementation, beyond the fortify macro
> usage (discussed with Siddhesh) and Paul's suggestion to open-code the
> copying and counting (which I declined).
>
> Thanks,
> Florian
>
> Florian Weimer (2):
> Implement strlcpy and strlcat [BZ #178]
> Add the wcslcpy, wcslcat functions
>
> Paul Eggert (1):
> manual: Manual update for strlcat, strlcpy, wcslcat, wclscpy
>
> NEWS | 3 +
> debug/Makefile | 4 +
> debug/Versions | 6 ++
> debug/strlcat_chk.c | 31 ++++++
> debug/strlcpy_chk.c | 31 ++++++
> debug/tst-fortify.c | 48 ++++++++++
> debug/wcslcat_chk.c | 31 ++++++
> debug/wcslcpy_chk.c | 31 ++++++
> include/string.h | 4 +
> include/wchar.h | 5 +
> manual/maint.texi | 8 ++
> manual/string.texi | 96 ++++++++++++++++++-
> string/Makefile | 4 +
> string/Versions | 4 +
> string/bits/string_fortified.h | 36 +++++++
> string/string.h | 13 +++
> string/strlcat.c | 59 ++++++++++++
> string/strlcpy.c | 46 +++++++++
> string/tst-strlcat.c | 84 ++++++++++++++++
> string/tst-strlcpy.c | 68 +++++++++++++
> sysdeps/mach/hurd/i386/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/aarch64/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/alpha/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/arc/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/arm/be/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/arm/le/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/csky/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/hppa/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/i386/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/ia64/libc.abilist | 8 ++
> .../sysv/linux/loongarch/lp64/libc.abilist | 8 ++
> .../sysv/linux/m68k/coldfire/libc.abilist | 8 ++
> .../unix/sysv/linux/m68k/m680x0/libc.abilist | 8 ++
> .../sysv/linux/microblaze/be/libc.abilist | 8 ++
> .../sysv/linux/microblaze/le/libc.abilist | 8 ++
> .../sysv/linux/mips/mips32/fpu/libc.abilist | 8 ++
> .../sysv/linux/mips/mips32/nofpu/libc.abilist | 8 ++
> .../sysv/linux/mips/mips64/n32/libc.abilist | 8 ++
> .../sysv/linux/mips/mips64/n64/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/nios2/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/or1k/libc.abilist | 8 ++
> .../linux/powerpc/powerpc32/fpu/libc.abilist | 8 ++
> .../powerpc/powerpc32/nofpu/libc.abilist | 8 ++
> .../linux/powerpc/powerpc64/be/libc.abilist | 8 ++
> .../linux/powerpc/powerpc64/le/libc.abilist | 8 ++
> .../unix/sysv/linux/riscv/rv32/libc.abilist | 8 ++
> .../unix/sysv/linux/riscv/rv64/libc.abilist | 8 ++
> .../unix/sysv/linux/s390/s390-32/libc.abilist | 8 ++
> .../unix/sysv/linux/s390/s390-64/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/sh/be/libc.abilist | 8 ++
> sysdeps/unix/sysv/linux/sh/le/libc.abilist | 8 ++
> .../sysv/linux/sparc/sparc32/libc.abilist | 8 ++
> .../sysv/linux/sparc/sparc64/libc.abilist | 8 ++
> .../unix/sysv/linux/x86_64/64/libc.abilist | 8 ++
> .../unix/sysv/linux/x86_64/x32/libc.abilist | 8 ++
> wcsmbs/Makefile | 4 +
> wcsmbs/Versions | 2 +
> wcsmbs/bits/wchar2.h | 37 +++++++
> wcsmbs/tst-wcslcat.c | 93 ++++++++++++++++++
> wcsmbs/tst-wcslcpy.c | 78 +++++++++++++++
> wcsmbs/wchar.h | 13 +++
> wcsmbs/wcslcat.c | 60 ++++++++++++
> wcsmbs/wcslcpy.c | 46 +++++++++
> 63 files changed, 1222 insertions(+), 3 deletions(-)
> create mode 100644 debug/strlcat_chk.c
> create mode 100644 debug/strlcpy_chk.c
> create mode 100644 debug/wcslcat_chk.c
> create mode 100644 debug/wcslcpy_chk.c
> create mode 100644 string/strlcat.c
> create mode 100644 string/strlcpy.c
> create mode 100644 string/tst-strlcat.c
> create mode 100644 string/tst-strlcpy.c
> create mode 100644 wcsmbs/tst-wcslcat.c
> create mode 100644 wcsmbs/tst-wcslcpy.c
> create mode 100644 wcsmbs/wcslcat.c
> create mode 100644 wcsmbs/wcslcpy.c
>
>
> base-commit: 65cbd52174f5bc211dd655727c2239e25e55bfce
> --
> 2.40.0
>
Should we add benchtests for them?
--
H.J.
next prev parent reply other threads:[~2023-04-20 16:20 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-20 12:28 Florian Weimer
2023-04-20 12:28 ` [PATCH v2 1/3] Implement strlcpy and strlcat [BZ #178] Florian Weimer
2023-06-06 5:41 ` Siddhesh Poyarekar
2023-06-14 9:04 ` Florian Weimer
2023-04-20 12:28 ` [PATCH v2 2/3] Add the wcslcpy, wcslcat functions Florian Weimer
2023-06-06 5:56 ` Siddhesh Poyarekar
2023-04-20 12:28 ` [PATCH v2 3/3] manual: Manual update for strlcat, strlcpy, wcslcat, wclscpy Florian Weimer
2023-06-06 6:03 ` Siddhesh Poyarekar
2023-06-06 12:27 ` Florian Weimer
2023-06-06 12:42 ` Siddhesh Poyarekar
2023-04-20 16:19 ` H.J. Lu [this message]
2023-04-21 17:46 ` [PATCH v2 0/3] strlcpy and related functions Florian Weimer
2023-04-22 0:25 ` Noah Goldstein
2023-04-28 10:48 ` Florian Weimer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAMe9rOoZN7hGVC2So=JkU7Ym3ZSOr2Y2NjYx=-5adDo04EUiZA@mail.gmail.com' \
--to=hjl.tools@gmail.com \
--cc=fweimer@redhat.com \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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 read-only IMAP folder(s) and NNTP newsgroup(s).