Re: [PATCH v4 1/2] man/man3/strto[u]l.3: BUGS: Signed numbers and white space are not rejected

Alejandro Colomar
2025-03-23T19:47:13Z

[-- Attachment #1: Type: text/plain, Size: 1388 bytes --]

On Sun, Mar 23, 2025 at 08:26:02PM +0100, Bruno Haible wrote:
> Alejandro Colomar wrote:
> > diff --git a/man/man3/strtoul.3 b/man/man3/strtoul.3
> > index c6a2bb9be..4e85f7a30 100644
> > --- a/man/man3/strtoul.3
> > +++ b/man/man3/strtoul.3
> > @@ -182,7 +187,7 @@ .SH VERSIONS
> > or to
> > .BR strtoul ().
> > .SH STANDARDS
> > -C11, POSIX.1-2008.
> > +C23, POSIX.1-2008.
> > .SH HISTORY
> > .TP
> > .BR strtoul ()
> > @@ -190,6 +195,10 @@ .SH HISTORY
> > .TP
> > .BR strtoull ()
> > POSIX.1-2001, C99.
> > +.TP
> > +"0b", "0B"
> > +C23.
> > +glibc 2.38.
> > .SH CAVEATS
> > Since
> > .BR strtoul ()
>
> These same two hunks could also be applied to strtol.3.

Yep, I had forgotten. I've applied them a moment ago. BTW, I also
updated the info about POSIX too:

<https://www.alejandro-colomar.es/src/alx/linux/man-pages/man-pages.git/commit/?h=contrib&id=2b2519c7722166dbe4313da6ec048d137ea42ba7>

@@ -183,7 +188,7 @@ .SH VERSIONS
or to
.BR strtol ().
.SH STANDARDS
-C11, POSIX.1-2008.
+C23, POSIX.1-2024.
.SH HISTORY
.TP
.BR strtol ()
@@ -191,6 +196,11 @@ .SH HISTORY
.TP
.BR strtoll ()
POSIX.1-2001, C99.
+.TP
+"0b", "0B"
+C23.
+glibc 2.38.
+(Not in POSIX.)
.SH CAVEATS
.SS Range checks
Since

Cheers,
Alex

--
<https://www.alejandro-colomar.es/>