<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glibc/libio/stdio.h, branch vdso</title>
<subtitle>Fork of glibc for development</subtitle>
<id>https://git.zx2c4.com/glibc/atom/libio/stdio.h?h=vdso</id>
<link rel='self' href='https://git.zx2c4.com/glibc/atom/libio/stdio.h?h=vdso'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/'/>
<updated>2024-06-11T21:17:12Z</updated>
<entry>
<title>&lt;stdio.h&gt;: Acknowledge that getdelim/getline are in POSIX</title>
<updated>2024-06-11T21:17:12Z</updated>
<author>
<name>Philip Kaludercic</name>
<email>philipk@posteo.net</email>
</author>
<published>2024-06-09T11:14:59Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=e7ac92e6ca9784b397189df0b2e1fb34f425bab8'/>
<id>urn:sha1:e7ac92e6ca9784b397189df0b2e1fb34f425bab8</id>
<content type='text'>
These comments were written in 2003 (added in 2c008571c3a), predating
the addition of getdelim(3)/getline(3) in POSIX.1-2008.

Reviewed-by: Sam James &lt;sam@gentoo.org&gt;
Reviewed-by: Florian Weimer &lt;fweimer@redhat.com&gt;
</content>
</entry>
<entry>
<title>Refer to C23 in place of C2X in glibc</title>
<updated>2024-02-01T11:02:01Z</updated>
<author>
<name>Joseph Myers</name>
<email>josmyers@redhat.com</email>
</author>
<published>2024-02-01T11:02:01Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=42cc619dfbc44e263239c2de870bae11ad65810a'/>
<id>urn:sha1:42cc619dfbc44e263239c2de870bae11ad65810a</id>
<content type='text'>
WG14 decided to use the name C23 as the informal name of the next
revision of the C standard (notwithstanding the publication date in
2024).  Update references to C2X in glibc to use the C23 name.

This is intended to update everything *except* where it involves
renaming files (the changes involving renaming tests are intended to
be done separately).  In the case of the _ISOC2X_SOURCE feature test
macro - the only user-visible interface involved - support for that
macro is kept for backwards compatibility, while adding
_ISOC23_SOURCE.

Tested for x86_64.
</content>
</entry>
<entry>
<title>Update copyright dates with scripts/update-copyrights</title>
<updated>2024-01-01T18:53:40Z</updated>
<author>
<name>Paul Eggert</name>
<email>eggert@cs.ucla.edu</email>
</author>
<published>2024-01-01T18:12:26Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=dff8da6b3e89b986bb7f6b1ec18cf65d5972e307'/>
<id>urn:sha1:dff8da6b3e89b986bb7f6b1ec18cf65d5972e307</id>
<content type='text'>
</content>
</entry>
<entry>
<title>libio: Add nonnull attribute for most FILE * arguments in stdio.h</title>
<updated>2023-09-27T00:11:38Z</updated>
<author>
<name>Xi Ruoyao</name>
<email>xry111@xry111.site</email>
</author>
<published>2023-09-25T11:53:26Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=64b1a44183a3094672ed304532bedb9acc707554'/>
<id>urn:sha1:64b1a44183a3094672ed304532bedb9acc707554</id>
<content type='text'>
During the review of a GCC analyzer test case, we found most stdio
functions accepting a FILE * argument expect it to be nonnull and just
segfault when the argument is NULL.  Add nonnull attribute for them.

fflush and fflush_unlocked are well defined when __stream is NULL so
they are not touched.

For fputs, fgets, fread, fwrite, fprintf, vfprintf, and their unlocked
version, if __stream is empty but there is nothing to read or write,
they did not segfault.  But the standard disallow __stream to be empty
here, so nonnull attribute is also added for them.  Note that this may
blow up some old code already subtly broken.

Also add __nonnull for _chk variants and __fortify_function versions for
them.

Signed-off-by: Xi Ruoyao &lt;xry111@xry111.site&gt;
Reviewed-by: Alejandro Colomar &lt;alx@kernel.org&gt;
Reviewed-by: Siddhesh Poyarekar &lt;siddhesh@sourceware.org&gt;
</content>
</entry>
<entry>
<title>libio: Add __nonnull for FILE * arguments of fclose and freopen</title>
<updated>2023-05-16T09:56:32Z</updated>
<author>
<name>Xi Ruoyao</name>
<email>xry111@xry111.site</email>
</author>
<published>2023-04-21T06:21:33Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=71d9e0fe766a3c22a730995b9d024960970670af'/>
<id>urn:sha1:71d9e0fe766a3c22a730995b9d024960970670af</id>
<content type='text'>
Calling fclose or freopen with a null FILE * is undefined behavior, and
doing so in practice will cause a SIGSEGV.  So it seems suitable for
__nonnull.

This will help the compiler to warn for some buggy code, like
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109570.
Reviewed-by: Adhemerval Zanella  &lt;adhemerval.zanella@linaro.org&gt;
</content>
</entry>
<entry>
<title>Mark various cold functions as __COLD</title>
<updated>2023-05-01T17:33:21Z</updated>
<author>
<name>Sergey Bugaev</name>
<email>bugaevc@gmail.com</email>
</author>
<published>2023-04-29T13:12:23Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=e6a252758cbadb13654e66e1f2445ef6f8a4dea0'/>
<id>urn:sha1:e6a252758cbadb13654e66e1f2445ef6f8a4dea0</id>
<content type='text'>
GCC docs explicitly list perror () as a good candidate for using
__attribute__ ((cold)). So apply __COLD to perror () and similar
functions.

Reviewed-by: Siddhesh Poyarekar &lt;siddhesh@sourceware.org&gt;
Signed-off-by: Sergey Bugaev &lt;bugaevc@gmail.com&gt;
Message-Id: &lt;20230429131223.2507236-3-bugaevc@gmail.com&gt;
</content>
</entry>
<entry>
<title>&lt;stdio.h&gt;: Make fopencookie, vasprintf, asprintf available by default</title>
<updated>2023-04-06T14:41:15Z</updated>
<author>
<name>Florian Weimer</name>
<email>fweimer@redhat.com</email>
</author>
<published>2023-04-06T14:40:44Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=0d5cb2ae27c0a163c15e5222fb132bf9d026b14b'/>
<id>urn:sha1:0d5cb2ae27c0a163c15e5222fb132bf9d026b14b</id>
<content type='text'>
FreeBSD makes these functions available by default, so we should
not treat them as GNU-specific and restrict them to _GNU_SOURCE.

Reviewed-by: Adhemerval Zanella  &lt;adhemerval.zanella@linaro.org&gt;
</content>
</entry>
<entry>
<title>libio: Do not autogenerate stdio_lim.h</title>
<updated>2023-03-27T16:57:55Z</updated>
<author>
<name>Adhemerval Zanella Netto</name>
<email>adhemerval.zanella@linaro.org</email>
</author>
<published>2023-03-06T18:53:55Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=f65ca70deaf38db4ca12458e74cefd8ad9063956'/>
<id>urn:sha1:f65ca70deaf38db4ca12458e74cefd8ad9063956</id>
<content type='text'>
Instead define the required fields in system dependend files.  The only
system dependent definition is FILENAME_MAX, which should match POSIX
PATH_MAX, and it is obtained from either kernel UAPI or mach headers.
Currently set pre-defined value from current kernels.

It avoids a circular dependendy when including stdio.h in
gen-as-const-headers files.

Checked on x86_64-linux-gnu and i686-linux-gnu
Reviewed-by: Carlos O'Donell &lt;carlos@redhat.com&gt;
</content>
</entry>
<entry>
<title>C2x scanf binary constant handling</title>
<updated>2023-03-02T19:10:37Z</updated>
<author>
<name>Joseph Myers</name>
<email>joseph@codesourcery.com</email>
</author>
<published>2023-03-02T19:10:37Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=dee2bea048b688b643a9a3b44b26ca9f7a706fe8'/>
<id>urn:sha1:dee2bea048b688b643a9a3b44b26ca9f7a706fe8</id>
<content type='text'>
C2x adds binary integer constants starting with 0b or 0B, and supports
those constants for the %i scanf format (in addition to the %b format,
which isn't yet implemented for scanf in glibc).  Implement that scanf
support for glibc.

As with the strtol support, this is incompatible with previous C
standard versions, in that such an input string starting with 0b or 0B
was previously required to be parsed as 0 (with the rest of the input
potentially matching subsequent parts of the scanf format string).
Thus this patch adds 12 new __isoc23_* functions per long double
format (12, 24 or 36 depending on how many long double formats the
glibc configuration supports), with appropriate header redirection
support (generally very closely following that for the __isoc99_*
scanf functions - note that __GLIBC_USE (DEPRECATED_SCANF) takes
precedence over __GLIBC_USE (C2X_STRTOL), so the case of GNU
extensions to C89 continues to get old-style GNU %a and does not get
this new feature).  The function names would remain as __isoc23_* even
if C2x ends up published in 2024 rather than 2023.

When scanf %b support is added, I think it will be appropriate for all
versions of scanf to follow C2x rules for inputs to the %b format
(given that there are no compatibility concerns for a new format).

Tested for x86_64 (full glibc testsuite).  The first version was also
tested for powerpc (32-bit) and powerpc64le (stdio-common/ and wcsmbs/
tests), and with build-many-glibcs.py.
</content>
</entry>
<entry>
<title>Update copyright dates with scripts/update-copyrights</title>
<updated>2023-01-06T21:14:39Z</updated>
<author>
<name>Joseph Myers</name>
<email>joseph@codesourcery.com</email>
</author>
<published>2023-01-06T21:08:04Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=6d7e8eda9b85b08f207a6dc6f187e94e4817270f'/>
<id>urn:sha1:6d7e8eda9b85b08f207a6dc6f187e94e4817270f</id>
<content type='text'>
</content>
</entry>
</feed>
