This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 0/9] Use more flags parameters instead of global bits in stdio
- From: Zack Weinberg <zackw at panix dot com>
- To: GNU C Library <libc-alpha at sourceware dot org>
- Date: Mon, 12 Mar 2018 11:29:52 -0400
- Subject: Re: [PATCH 0/9] Use more flags parameters instead of global bits in stdio
- Authentication-results: sourceware.org; auth=none
- References: <20180307193205.4751-1-zackw@panix.com>
On Wed, Mar 7, 2018 at 2:31 PM, Zack Weinberg <zackw@panix.com> wrote:
> I got stuck on the patch to use C99-compliant scanf in _GNU_SOURCE
> mode because the interaction with ldbl-is-dbl was too confusing. The
> reason it's too confusing is that C99 compliance in scanf, ldbl-is-dbl
> mode in scanf, printf, and strfmon, and fortify mode in printf are
> handled with mode bits on the FILE and thread-global flags that must
> be set and reset at just the right times. Correct behavior is
> invariably to set and then reset around just one call to a lower-level
> function, and there's a better way to do that: flags parameters.
>
> This patch series implements _internal variants of scanf, printf,
> strfmon, and syslog that take flag parameters that control C99
> compliance, ldbl-is-dbl mode, and fortification.
Ping? These patches have now survived build-many-glibcs testing on
all supported platforms except the Hurd (I still can't successfully
build an i686-gnu cross compiler) and are waiting for review. Note
that an expanded version of the "post-cleanup" has already been
committed.
zw