Go to file
Sergey Kolosov 8ca2fe7e96 resolv: Add tests for getaddrinfo returning EAI_AGAIN [BZ #16849]
This patch adds two tests that verify correct behavior of getaddrinfo
when DNS resolution fails with a temporary error. Both tests ensure
that getaddrinfo returns EAI_AGAIN in cases where no valid address can
be resolved due to network or resolver failure.

* tst-getaddrinfo-eai-again.c
  Runs inside the glibc test-container without any DNS server
  configured. The test performs queries using AF_INET, AF_INET6,
  and AF_UNSPEC and verifies that getaddrinfo returns EAI_AGAIN
  when resolution fails.

* tst-getaddrinfo-eai-again-timeout.c
  Runs outside of the container but uses the resolv_test framework
  to simulate network failures. The test covers two failure modes:
  - No response from the server (resolv_response_drop)
  - Zero-length reply from the server
  In both cases, getaddrinfo is expected to return EAI_AGAIN.

Reviewed-by: Florian Weimer <fweimer@redhat.com>
2025-10-10 17:15:27 +02:00
ChangeLog.old
advisories
argp
assert assert: Refactor assert/assert_perror 2025-09-23 10:29:24 -03:00
benchtests benchtests: Improve fmod benchmark 2025-10-08 10:42:22 -03:00
bits Add once_flag, ONCE_FLAG_INIT and call_once to stdlib.h for C23 2025-10-01 15:15:15 +00:00
catgets
conform
csu
ctype
debug Implement C23 memset_explicit (bug 32378) 2025-10-01 15:14:09 +00:00
dirent
dlfcn
elf elf: Report when found libraries are rejected [BZ #25669] 2025-10-08 10:43:18 -03:00
gmon
gnulib
hesiod
htl
hurd hurd: Fix building on i686-gnu 2025-09-23 21:43:59 +02:00
iconv misc: Fix several typos 2025-10-10 14:52:40 +01:00
iconvdata
include misc: Fix several typos 2025-10-10 14:52:40 +01:00
inet
intl
io Tests: Create files with mode 0666, not 0777 (bug 33171) 2025-09-01 15:12:28 +02:00
libio libio: Add terminating NUL when the first character is EOF in getdelim [BZ #28038] 2025-10-09 17:38:01 -07:00
locale
localedata tests-mbwc/tst_funcs.h: Fix typo 2025-10-01 14:49:10 -03:00
login login: fix ut_line comparison logic 2025-08-29 14:49:19 -04:00
mach
malloc malloc: Do not call madvise if oldsize >= THP size 2025-10-08 12:59:30 +00:00
manual manual: check the correct variable in SIOCATMARK example [BZ #33093] 2025-10-06 19:14:59 -07:00
math AArch64: Implement AdvSIMD and SVE log10p1(f) routines 2025-09-27 12:45:59 +00:00
mathvec
misc atomics: Remove unused atomics 2025-09-10 09:18:06 +00:00
nis
nptl atomic: Remove atomic_forced_read 2025-10-08 12:59:30 +00:00
nptl_db
nscd atomic: Remove atomic_forced_read 2025-10-08 12:59:30 +00:00
nss Alphabetize nss/Makefile 2025-10-09 09:50:27 +02:00
po
posix shm-directory: Truncated struct member name length 2025-10-01 14:49:10 -03:00
resolv resolv: Add tests for getaddrinfo returning EAI_AGAIN [BZ #16849] 2025-10-10 17:15:27 +02:00
resource
rt
scripts Use Linux 6.17 in build-many-glibcs.py 2025-10-01 15:15:43 +00:00
setjmp
signal
socket
soft-fp
stdio-common libio: Define AT_RENAME_* with the same tokens as Linux 2025-09-05 19:02:59 +02:00
stdlib Add once_flag, ONCE_FLAG_INIT and call_once to stdlib.h for C23 2025-10-01 15:15:15 +00:00
string Implement C23 memset_explicit (bug 32378) 2025-10-01 15:14:09 +00:00
sunrpc
support support: Add support_accept_oom to heuristically support OOM errors 2025-09-18 19:11:38 +02:00
sysdeps misc: Fix several typos 2025-10-10 14:52:40 +01:00
sysvipc
termios
time
timezone
wcsmbs
wctype
.b4-config
.clang-format
.gitattributes
.gitignore
CONTRIBUTED-BY
COPYING
COPYING.LIB
INSTALL
LICENSES
MAINTAINERS
Makeconfig
Makefile
Makefile.help
Makefile.in
Makerules
NEWS Implement C23 memset_explicit (bug 32378) 2025-10-01 15:14:09 +00:00
README
Rules
SECURITY.md
SHARED-FILES SHARED-FILES: Adjust core-math entries 2025-09-11 14:46:07 -03:00
abi-tags
aclocal.m4
config.h.in hurd: implement RLIMIT_AS against Mach RPCs 2025-09-22 00:52:37 +02:00
config.make.in
configure
configure.ac
extra-lib.mk
gen-locales.mk
libc-abis
libof-iterator.mk
o-iterator.mk
shlib-versions
test-skeleton.c
version.h

README

This directory contains the sources of the GNU C Library.
See the file "version.h" for what release version you have.

The GNU C Library is the standard system C library for all GNU systems,
and is an important part of what makes up a GNU system.  It provides the
system API for all programs written in C and C-compatible languages such
as C++ and Objective C; the runtime facilities of other programming
languages use the C library to access the underlying operating system.

In GNU/Linux systems, the C library works with the Linux kernel to
implement the operating system behavior seen by user applications.
In GNU/Hurd systems, it works with a microkernel and Hurd servers.

The GNU C Library implements much of the POSIX.1 functionality in the
GNU/Hurd system, using configurations i[4567]86-*-gnu and x86_64-gnu.

When working with Linux kernels, this version of the GNU C Library
requires Linux kernel version 3.2 or later.

Also note that the shared version of the libgcc_s library must be
installed for the pthread library to work correctly.

The GNU C Library supports these configurations for using Linux kernels:

	aarch64*-*-linux-gnu
	alpha*-*-linux-gnu
	arc*-*-linux-gnu
	arm-*-linux-gnueabi
	csky-*-linux-gnuabiv2
	hppa-*-linux-gnu
	i[4567]86-*-linux-gnu
	x86_64-*-linux-gnu	Can build either x86_64 or x32
	loongarch64-*-linux-gnu Hardware floating point, LE only.
	m68k-*-linux-gnu
	microblaze*-*-linux-gnu
	mips-*-linux-gnu
	mips64-*-linux-gnu
	or1k-*-linux-gnu
	powerpc-*-linux-gnu	Hardware or software floating point, BE only.
	powerpc64*-*-linux-gnu	Big-endian and little-endian.
	s390-*-linux-gnu
	s390x-*-linux-gnu
	riscv32-*-linux-gnu
	riscv64-*-linux-gnu
	sh[34]-*-linux-gnu
	sparc*-*-linux-gnu
	sparc64*-*-linux-gnu

If you are interested in doing a port, please contact the glibc
maintainers; see https://www.gnu.org/software/libc/ for more
information.

See the file INSTALL to find out how to configure, build, and install
the GNU C Library.  You might also consider reading the WWW pages for
the C library at https://www.gnu.org/software/libc/.

The GNU C Library is (almost) completely documented by the Texinfo manual
found in the `manual/' subdirectory.  The manual is still being updated
and contains some known errors and omissions; we regret that we do not
have the resources to work on the manual as much as we would like.  For
corrections to the manual, please file a bug in the `manual' component,
following the bug-reporting instructions below.  Please be sure to check
the manual in the current development sources to see if your problem has
already been corrected.

Please see https://www.gnu.org/software/libc/bugs.html for bug reporting
information.  We are now using the Bugzilla system to track all bug reports.
This web page gives detailed information on how to report bugs properly.

The GNU C Library is free software.  See the file COPYING.LIB for copying
conditions, and LICENSES for notices about a few contributions that require
these additional notices to be distributed.  License copyright years may be
listed using range notation, e.g., 1996-2015, indicating that every year in
the range, inclusive, is a copyrightable year that would otherwise be listed
individually.