1
0
mirror of https://sourceware.org/git/glibc.git synced 2026-01-06 11:51:29 +03:00

linux: Handle EINVAL as unsupported on tst-pidfd_getinfo

Some kernels returns EINVAL for ioctl (PIDFD_GET_INFO) on pidfd
descriptors.

Checked on aarch64-linux-gnu with Linux 6.12.

Reviewed-by: Florian Weimer <fweimer@redhat.com>
This commit is contained in:
Adhemerval Zanella
2025-11-20 16:42:04 -03:00
parent 52524467af
commit 907089ba36

View File

@@ -46,7 +46,7 @@ do_test (void)
};
if (ioctl (pidfd, PIDFD_GET_INFO, &info) != 0)
{
if (errno == ENOTTY)
if (errno == ENOTTY || errno == EINVAL)
FAIL_UNSUPPORTED ("kernel does not support PIDFD_GET_INFO");
else
FAIL_EXIT1 ("ioctl (PIDFD_GET_INFO) failed: %m");