The GNU C Library is used as *the* C library in the GNU system and
in GNU/Linux systems, as well as many other systems that use Linux
as the kernel.
The GNU C Library is primarily designed to be a portable
and high performance C library. It follows all relevant
standards including ISO C23 and POSIX.1-2024. It is also
internationalized and has one of the most complete
internationalization interfaces known.
The GNU C Library website is at http://www.gnu.org/software/libc/
Packages for the 2.42 release may be downloaded from:
http://ftpmirror.gnu.org/libc/
http://ftp.gnu.org/gnu/libc/
The mirror list is at http://www.gnu.org/order/ftp.html
Distributions are encouraged to track the release/* branches
corresponding to the releases they are using. The release
branches will be updated with conservative bug fixes and new
features while retaining backwards compatibility.
NEWS for version 2.42
=====================
Major new features:
* The following ISO C23 function families (introduced in TS
18661-4:2015) are now supported in <math.h>. Each family includes
functions for float, double, long double, _FloatN and _FloatNx, and a
type-generic macro in <tgmath.h>.
- Power and absolute-value functions: compoundn, pown, powr, rootn,
rsqrt.
* On Linux, the pthread_gettid_np function has been added.
* The ISO C2Y family of unsigned abs functions, i.e. uabs, ulabs,
ullabs, and uimaxabs, is now supported.
* On Linux, the <termios.h> interface now supports arbitrary baud rates;
speed_t is redefined to simply be the baud rate specified as an
unsigned int, which matches the kernel interface.
* The thread-local cache in malloc (tcache) now supports caching of
large blocks. This feature can be enabled by setting the tunable
glibc.malloc.tcache_max to a larger value (max 4194304). Tcache is
also significantly faster for small sizes.
* A new configure option, "--enable-sframe", can be used to enable
SFrame support of the GNU C Libraries. SFrame is a new stack trace
information format which can be used by backtrace. It requires
binutils with a minimum version of 2.45.
* Support for lightweight stack guard pages via madvise and the
MADV_GUARD_INSTALL flag has been added to pthread_create.
* Additional optimized and correctly rounded mathematical functions have
been imported from the CORE-MATH project, in particular acospif,
asinpif, atanpif, atan2pif, cospif, sinpif, tanpif.
* The testsuite has been significantly extended, including coverage of
the functionality of the printf and scanf function families in many
variants.
* The manual has been significantly extended and updated, particularly
the threads, terminal, filesystem, resource, and math chapters.
* Code has been added to detect the x86-64 Intel Arrow Lake, Panther
Lake, Clearwater Forest, and Diamond Rapids microarchitectures.
* Regarding S390, support for the new z17 platform has been added.
Deprecated and removed features, and other changes affecting compatibility:
* The glibc.rtld.execstack tunable now supports a compatibility mode to
allow programs that require an executable stack through dynamically
loaded shared libraries.
* On Linux, the <termio.h> header and the definition of struct termio
in <sys/ioctl.h> have been removed. The termio interface has been
obsolete since the very first version of POSIX.1 in 1988, replaced
with <termios.h>.
* The support for TX lock elision of pthread mutexes has been deprecated
on all architectures and will be removed in the next release.
* On AArch64 Linux targets supporting the Scalable Matrix Extension
(SME), setjmp and sigsetjmp will disable the ZA state of SME.
Changes to build and runtime requirements:
* GCC 12.1 or later is now required to build the GNU C Library.
* GNU Binutils 2.39 or later is now required to build the GNU C Library.
Security related changes:
The following CVEs were fixed in this release, details of which can be
found in the advisories directory of the release tarball:
GLIBC-SA-2025-0001:
assert: Buffer overflow when printing assertion failure message
(CVE-2025-0395)
GLIBC-SA-2025-0003:
power10: strcmp fails to save and restore nonvolatile vector
registers (CVE-2025-5702)
GLIBC-SA-2025-0004:
power10: strncmp fails to save and restore nonvolatile vector
registers (CVE-2025-5745)
GLIBC-SA-2025-0005:
posix: Fix double-free after allocation failure in regcomp
(CVE-2025-8058)
The following bugs were resolved with this release:
[5994] stdio: fflush after ungetc on seekable input stream
[12724] stdio: fclose violates POSIX 2008 on seekable input streams
[25263] dynamic-link: ldd and ld.so fail to resolve $ORIGIN with cross
dir symlink
[27880] nptl: Please provide a pthread pid accessor
[29190] dynamic-link: Symbols with version hash zero lead to crashes,
not matched correctly
[29459] stdio: fwrite does not return EPIPE when underlying write
fails with EPIPE.
[31791] nss: [Regression] nss: memory for >8 elements in nsswitch.conf
is not freed
[32058] libc: qsort leaks memory if C++ exception is thrown from
comparison function
[32269] dynamic-link: RISC-V IFUNC resolver cannot access gp pointer
[32369] stdio: fflush(NULL) doesn't properly flush files opened in
read mode
[32411] math: THREEp96 seems wrong
[32412] dynamic-link: Initial DTV is reallocated using main realloc in
auditing mode
[32483] locale: ctype.h macros segfault in multithreaded programs with
multiple libc.so
[32529] stdio: fseek failure on file opened with "rm" mode after
ungetc
[32535] stdio: fflush failure on file opened with "rm" mode after
ungetc
[32541] libc: getenv cannot be overridden in static builds
[32574] libc: pthread_attr_getstacksize/pthread_attr_getstack return
incorrect main stack size
[32612] dynamic-link: [aarch64 PAC] _dl_tlsdesc_dynamic can't be
unwound through with _Unwind_Backtrace
[32626] math: math: log10p1f is not correctly rounded
[32627] math: math: sinhf is not correctly rounded
[32630] math: math: tanf is not correctly rounded for all rounding
modes
[32653] dynamic-link: Review options for improving both security and
backwards compatibility of glibc 2.41 dlopen / execstack handling
[32694] math: wrong clang version 3.4 prereq checks in bits/floatn.h
for __float128 support, should be 3.9
[32708] libc: Inclusion of sys/mount.h triggers many gcc warnings
using -Wshift-overflow=2 -Wsystem-headers
[32711] math: math: remainder incorrect sign of zero result
[32717] libc: glibc tests fail when bfd is built with --enable-error-
execstack=yes
[32723] math: [2.41 Regression] /usr/include/bits/floatn.h doesn't
work with Intel SYCL compiler
[32763] dynamic-link: Static PIE with more than one PT_LOAD segments
at offset 0 segfault
[32777] crypt: The performance of the rand() function degradation
[32781] libc: Inccorect attribute access for sched_getattr
[32782] nptl: Race conditions in pthread cancellation causing crash
[32786] nptl: pthread_cond_* symbols should probably have had a
version bump in 2.41
[32795] nptl: aio_suspend_time64 confuses CLOCK_MONOTONIC and
CLOCK_REALTIME
[32810] dynamic-link: Immediate crash on x86-64 when running with
GLIBC_TUNABLES=glibc.cpu.hwcaps=-XSAVEC
[32823] libc: make[2]: *** [../Rules:248:
/home/dave/gnu/glibc/objdir/elf/tst-origin] Error 1
[32897] dynamic-link: pthread_getattr_np fails when executable stack
tunable is set
[32918] math: math: atanhf triggers UB
[32919] math: math: coshf triggers UB
[32920] math: math: logf triggers UB
[32921] math: math: sinhf triggers UB
[32922] math: math: cbrtf triggers UB
[32923] math: math: cospif triggers UB
[32924] math: math: erfcf triggers UB
[32925] math: math: sinpif triggers UB
[32932] libc: riscv: __riscv_hwprobe function attributes are incorrect
[32947] libc: stdlib: wrong iovec array size on __libc_message_impl
[32980] manual: getopt_long_only does not check long options first, as
the manual claims
[32981] ports: elf/tst-execstack-prog-static-tunable fails on
sparc64-linux-gnu
[32987] libc: New tst-dlopen-sgid test FAILs
[32996] malloc: i386 TLS helper functions don't preserve XMM registers
[33035] libc: [2.27 regression] Linux: __close_nocancel_nostatus
clobbers errno
[33056] string: Power 10 strcmp clobbers nonvolatile vector registers
(CVE-2025-5702)
[33059] string: Power 10 memchr clobbers v20
[33060] string: Power 10 strncmp clobbers nonvolatile vector registers
(CVE-2025-5745)
[33088] dynamic-link: __ehdr_start may need run-time relocation
[33089] build: [2.42 Regression] GCC 14.2.1 failed to build glibc
[33134] libc: mcount_internal shouldn't use vector/r16-r31 registers
nor call memcpy/memset
[33139] stdio: %n after static dlopen is unreliable if file
descriptors are exhausted
[33165] build: [2.42 Regression] FAIL: elf/check-localplt
[33173] math: Wrong IFUNC selector is used for modf/modff
[33185] regex: Double-free after memory allocation failure in regcomp
bracket expression parsing (CVE-2025-8058)
[33224] dynamic-link: _dl_debug_state hook no longer works (since
8329939a37f483a16013dd8af8303cbcb86d92cb)
Release Notes
=============
https://sourceware.org/glibc/wiki/Release/2.42
Contributors
============
This release was made possible by the contributions of many people.
The maintainers are grateful to everyone who has contributed
changes or bug reports. These include:
Aaron Merey
Adhemerval Zanella
Andreas K. Hüttel
Andreas Schwab
Andrew Pinski
Arjun Shankar
Aurelien Jarno
Ben Kallus
Carlos O'Donell
Claudiu Zissulescu
Colin Ian King
Collin Funk
Cupertino Miranda
Cœur
DJ Delorie
David Lau
Dylan Fleming
Flavio Cruz
Florian Weimer
Frédéric Bérat
H. Peter Anvin
H.J. Lu
Jakub Jelinek
Jeremy Harris
Jitka Obselkova
John David Anglin
Jonathan Wakely
Joseph Myers
Julian Zhu
Lenard Mollenkopf
Luca Dariz
Luna Lamb
Maciej W. Rozycki
Mark Harris
Mark Wielaard
Martin Coufal
Matteo Croce
Michael Jeanson
Paul Zimmermann
Petr Malat
Pierre Blanchard
Radko Krkos
Ravina Jain
Ronan Pigott
Sachin Monga
Sam James
Samuel Thibault
Samuel Zeter
Sergei Zimmerman
Sergey Bugaev
Sergey Kolosov
Siddhesh Poyarekar
Stefan Liebler
Sunil K Pandey
Tobias Stoeckmann
Tomas Volf
Tulio Magno Quites Machado Filho
Wilco Dijkstra
William Hunt
Xi Ruoyao
YLK
Yangyu Chen
Yat Long Poon
Yury Khrustalev
Zhaoming Luo
gfleury
koraynilay
panzhe0328
zhenwei pi
наб
We would like to call out the following and thank them for their
tireless patch review:
Adhemerval Zanella
Andreas K. Hüttel
Andreas Schwab
Arjun Shankar
Carlos O'Donell
Collin Funk
Cupertino Miranda
DJ Delorie
Florian Weimer
Frédéric Bérat
Geoffrey Thomas
guoce
H.J. Lu
Joseph Myers
Maciej W. Rozycki
Mark Harris
Matthieu Longo
Palmer Dabbelt
Paul Eggert
Peter Bergner
Sachin Monga
Sam James
Samuel Thibault
Stefan Liebler
Sunil K Pandey
Tulio Magno Quites Machado Filho
Wilco Dijkstra
Yury Khrustalev
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2