glibc/sysdeps/unix/sysv/linux
Florian Weimer cccb6d4e87 sigwait: Do not fail with EINTR and return error code [BZ #22478]
Since

commit 8b0e795aaa
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Wed Nov 1 11:49:05 2017 -0200

    Simplify Linux sig{timed}wait{info} implementations

sigwait can fail with EINTR.  Applications do not expect that, and the
error code is not documented in POSIX or the manual pages.

This commit restores the previous behavior by retrying the system call
on EINTR.  It also returns the error code, not -1, on the remaing
errors.

Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
2017-11-23 11:20:53 +01:00
..
aarch64 Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
alpha Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
arm Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
bits Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
generic Hide __chmod and __mkdir [BZ #18822] 2017-09-04 13:38:51 -07:00
hppa Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
i386 Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
ia64 Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
include Hide internal __sysinfo function [BZ #18822] 2017-10-01 16:05:28 -07:00
m68k Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
microblaze Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
mips Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
net Add Linux 4.14 ARPHRD_RAWIP to net/if_arp.h. 2017-11-16 17:52:43 +00:00
netash
netatalk
netax25
neteconet
netinet
netipx
netiucv
netpacket
netrom
netrose
nfs
nios2 Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
powerpc Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
s390 Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
scsi
sh Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
sparc Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
sys sys/ptrace.h: remove obsolete Linux PTRACE_SEIZE_DEVEL constant [BZ #21928] 2017-08-09 22:58:45 +00:00
tile Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
wordsize-64 Mark internal dirent functions with attribute_hidden [BZ #18822] 2017-10-01 15:51:11 -07:00
x86 Fix mcontext_t sigcontext namespace (bug 21457). 2017-08-30 22:02:04 +00:00
x86_64 Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
Implies
Makefile Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
Versions Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
_G_config.h
_exit.c
a.out.h
accept.c
accept4.c
access.c tunables: Use direct syscall for access (BZ#21744) 2017-07-24 11:21:07 -03:00
adjtime.c
aio_misc.h
aio_sigqueue.c aio: Remove internal_function function attribute 2017-08-31 15:59:06 +02:00
arch-fork.h
bind.c
check_native.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
check_pf.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
clock.c
clock_getcpuclockid.c
clock_getres.c
clock_gettime.c
clock_nanosleep.c
clock_settime.c
close.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
cmsg_nxthdr.c
configure
configure.ac
connect.c
creat.c
creat64.c
createthread.c
default-sched.h
device-nrs.h
dl-brk.c
dl-execstack.c NPTL: Remove internal_function from stack marking functions 2017-08-13 21:11:38 +02:00
dl-fxstatat64.c
dl-getcwd.c
dl-librecon.h
dl-openat64.c
dl-opendir.c
dl-origin.c
dl-osinfo.h
dl-sbrk.c
dl-sysdep.c
dl-sysdep.h
dl-vdso.c elf: Remove internal_function attribute 2017-08-31 16:59:37 +02:00
dl-vdso.h elf: Remove internal_function attribute 2017-08-31 16:59:37 +02:00
dl-writev.h
epoll_pwait.c
epoll_wait.c linux: Include <sysdep-cancel.h> for epoll_wait 2017-11-15 14:40:17 -02:00
errqueue.h Consistently use uintN_t not u_intN_t everywhere. 2017-08-07 19:55:34 +00:00
eventfd_read.c
eventfd_write.c
exit-thread.h
faccessat.c
fallocate.c
fallocate64.c
fatal-prepare.h
fchmodat.c
fcntl.c Remove NO_CANCELLATION macro 2017-08-31 16:10:34 -03:00
fd_to_filename.h
fdatasync.c
fexecve.c Fix fexecve build where syscall macros call sizeof. 2017-09-19 15:50:38 +00:00
filter-nr-syscalls.awk <bits/syscall.h>: Use an arch-independent system call list on Linux 2017-08-28 11:58:52 +02:00
fips-private.h Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
fpathconf.c
fstatfs64.c
fstatvfs.c Mark __internal_statvfs[64] with attribute_hidden [BZ #18822] 2017-10-01 15:08:32 -07:00
fstatvfs64.c Mark __internal_statvfs[64] with attribute_hidden [BZ #18822] 2017-10-01 15:08:32 -07:00
fsync.c
ftime.c
ftruncate.c
ftruncate64.c
futex-internal.h
futimens.c
futimes.c
futimesat.c
fxstat.c
fxstat64.c
fxstatat.c
fxstatat64.c
gai_sigqueue.c resolv: Remove internal_function attribute 2017-08-31 16:07:52 +02:00
gen-syscall-h.awk <bits/syscall.h>: Use an arch-independent system call list on Linux 2017-08-28 11:58:52 +02:00
gentempfd.c Include <string.h> for strcmp call from sysdeps/unix/sysv/linux/gentempfd.c. 2017-09-01 17:14:43 +00:00
getclktck.c
getcwd.c Linux getcwd: Remove internal_function attribute 2017-08-31 15:59:07 +02:00
getdents.c dirent: Remove internal_function attribute 2017-08-31 16:02:40 +02:00
getdents64.c
getdirentries.c
getdirentries64.c
getdtsz.c
getentropy.c
gethostid.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
getipv4sourcefilter.c
getloadavg.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
getlogin.c
getlogin_r.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
getpagesize.c
getpeername.c
getpriority.c
getpt.c Hide internal __bsd_getpt function [BZ #18822] 2017-10-01 16:08:42 -07:00
getrandom.c
getrlimit.c
getrlimit64.c Hide internal __new_getrlimit function [BZ #18822] 2017-10-01 18:00:07 -07:00
getsockname.c
getsockopt.c
getsourcefilter.c Hide internal __get_sol function [BZ #18822] 2017-10-01 16:12:24 -07:00
getsourcefilter.h Hide internal __get_sol function [BZ #18822] 2017-10-01 16:12:24 -07:00
getsysstats.c Hide internal sysinfo functions [BZ #18822] 2017-10-01 15:57:21 -07:00
gettimeofday.c
glob-lstat-compat.c posix: Add compat glob symbol to not follow dangling symbols 2017-09-25 18:04:16 -07:00
glob.c posix: Add compat glob symbol to not follow dangling symbols 2017-09-25 18:04:16 -07:00
glob64-lstat-compat.c posix: Add compat glob symbol to not follow dangling symbols 2017-09-25 18:04:16 -07:00
glob64.c Hide internal __glob64 function [BZ #18822] 2017-10-01 18:02:10 -07:00
globfree.c posix: Consolidate Linux glob implementation 2017-09-08 16:34:02 +02:00
globfree64.c posix: Consolidate Linux glob implementation 2017-09-08 16:34:02 +02:00
grantpt.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
if_index.c Check length of ifname before copying it into to ifreq structure. 2017-11-15 08:58:48 -08:00
ifaddrs.c Update sysdeps/unix/sysv/linux/ifaddrs.c 2017-09-27 17:18:32 -07:00
ifreq.c
internal_statvfs.c Mark __internal_statvfs[64] with attribute_hidden [BZ #18822] 2017-10-01 15:08:32 -07:00
internal_statvfs.h Mark __internal_statvfs[64] with attribute_hidden [BZ #18822] 2017-10-01 15:08:32 -07:00
internal_statvfs64.c
ipc_ops.h
ipc_priv.h
kernel-features.h Use execveat syscall in fexecve (bug 22134) 2017-09-19 16:19:14 +02:00
kernel-posix-cpu-timers.h
kernel-posix-timers.h
kernel_sigaction.h
kernel_stat.h
kernel_termios.h
ldd-rewrite.sed
lddlibc4.c
ldsodefs.h
libc_fatal.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
linux_fsinfo.h
listen.c
local-setxid.h
lowlevellock-futex.h
lseek.c
lseek64.c
lutimes.c
lxstat.c
lxstat64.c
malloc-sysdep.h Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
mmap.c posix: Fix mmap for m68k and ia64 (BZ#21908) 2017-08-14 10:35:14 -03:00
mmap64.c
mmap_internal.h posix: Fix mmap for m68k and ia64 (BZ#21908) 2017-08-14 10:35:14 -03:00
mq_close.c
mq_getattr.c
mq_notify.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
mq_open.c
mq_receive.c
mq_send.c
mq_timedreceive.c
mq_timedsend.c
mq_unlink.c
msgctl.c
msgget.c
msgrcv.c
msgsnd.c
msync.c
nanosleep.c Consolidate non cancellable nanosleep call 2017-08-22 14:25:08 -03:00
netlink_assert_response.c __netlink_assert_response: Remove internal_function attribute 2017-08-13 21:11:28 +02:00
netlinkaccess.h Mark internal netlink functions with attribute_hidden [BZ #18822] 2017-10-01 15:56:27 -07:00
nice.c
not-cancel.h Remove NO_CANCELLATION macro 2017-08-31 16:10:34 -03:00
not-errno.h tunables: Use direct syscall for access (BZ#21744) 2017-07-24 11:21:07 -03:00
nptl-signals.h
nscd_setup_thread.c
ntp_gettime.c
ntp_gettimex.c
olddirent.h Mark internal functions with attribute_hidden [BZ #18822] 2017-10-01 15:07:23 -07:00
oldglob.c posix: Add compat glob symbol to not follow dangling symbols 2017-09-25 18:04:16 -07:00
open.c Consolidate non cancellable open call 2017-08-17 16:50:35 -03:00
open64.c Consolidate non cancellable open call 2017-08-17 16:50:35 -03:00
open_by_handle_at.c
openat.c Consolidate non cancellable openat call 2017-08-18 16:30:05 -03:00
openat64.c Consolidate non cancellable openat call 2017-08-18 16:30:05 -03:00
opendir.c
opensock.c __opensock: Remove internal_function attribute 2017-08-17 10:18:15 +02:00
pathconf.c
pathconf.h Mark internal statfs functions with attribute_hidden [BZ #18822] 2017-10-01 15:18:25 -07:00
paths.h
pause.c Consolidate non cancellable pause call 2017-08-22 14:25:03 -03:00
personality.c
poll.c
posix_fadvise.c
posix_fadvise64.c Hide internal fadvise64/fallocate64 functions [BZ #18822] 2017-10-01 18:06:04 -07:00
posix_fallocate.c
posix_fallocate64.c Hide internal fadvise64/fallocate64 functions [BZ #18822] 2017-10-01 18:06:04 -07:00
posix_madvise.c
ppoll.c
pread.c
pread64.c
preadv.c posix: Remove internal_function attribute 2017-08-31 18:52:00 +02:00
preadv2.c posix: Set p{read,write}v2 to return ENOTSUP (BZ#21780) 2017-08-08 09:59:46 -03:00
preadv64.c posix: Remove internal_function attribute 2017-08-31 18:52:00 +02:00
preadv64v2.c posix: Set p{read,write}v2 to return ENOTSUP (BZ#21780) 2017-08-08 09:59:46 -03:00
prlimit.c
prof-freq.c
profil.c
pselect.c
pt-raise.c
pthread-pids.h
pthread_getaffinity.c
pthread_getcpuclockid.c
pthread_getname.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
pthread_kill.c
pthread_setaffinity.c
pthread_setname.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
pthread_sigmask.c
pthread_sigqueue.c
ptrace.c
ptsname.c
pwrite.c
pwrite64.c
pwritev.c posix: Remove internal_function attribute 2017-08-31 18:52:00 +02:00
pwritev2.c posix: Set p{read,write}v2 to return ENOTSUP (BZ#21780) 2017-08-08 09:59:46 -03:00
pwritev64.c posix: Remove internal_function attribute 2017-08-31 18:52:00 +02:00
pwritev64v2.c posix: Set p{read,write}v2 to return ENOTSUP (BZ#21780) 2017-08-08 09:59:46 -03:00
raise.c
read.c Consolidate non cancellable read call 2017-08-18 10:31:16 -03:00
readahead.c
readdir64.c Mark internal dirent functions with attribute_hidden [BZ #18822] 2017-10-01 15:51:11 -07:00
readdir64_r.c
readonly-area.c
readv.c Hide __readv and __writev [BZ #18822] 2017-10-01 15:54:10 -07:00
reboot.c
recv.c
recvfrom.c
recvmmsg.c
recvmsg.c
remove.c
rename.c
renameat.c
sa_len.c
safe-fatal.h
sched_getaffinity.c
sched_getcpu.c
sched_setaffinity.c Hide internal __sched_setaffinity_new function [BZ #18822] 2017-10-01 18:03:59 -07:00
segfault.c
select.c
semctl.c
semget.c
semop.c
semtimedop.c
send.c
sendmmsg.c
sendmsg.c
sendto.c
setegid.c
seteuid.c
setgid.c
setgroups.c
sethostid.c
setipv4sourcefilter.c
setregid.c
setresgid.c
setresuid.c
setreuid.c
setrlimit.c Hide internal __setrlimit function [BZ #18822] 2017-10-01 17:46:54 -07:00
setrlimit64.c Hide internal __setrlimit function [BZ #18822] 2017-10-01 17:46:54 -07:00
setsockopt.c
setsourcefilter.c Hide internal __get_sol function [BZ #18822] 2017-10-01 16:12:24 -07:00
setuid.c
shlib-versions
shm-directory.c
shmat.c
shmctl.c
shmdt.c
shmget.c
shutdown.c
sigaction.c
siglist.h
signal.c
signalfd.c
sigpending.c
sigprocmask.c Remove useless #ifdefs from Linux sig*.c syscalls 2017-10-31 17:49:18 -02:00
sigqueue.c Cleanup Linux sigqueue implementation 2017-11-06 17:37:57 -02:00
sigreturn.c
sigset-cvt-mask.h
sigsetops.h
sigstack.c
sigsuspend.c
sigtimedwait.c Simplify Linux sig{timed}wait{info} implementations 2017-11-06 17:37:57 -02:00
sigwait.c sigwait: Do not fail with EINTR and return error code [BZ #22478] 2017-11-23 11:20:53 +01:00
sigwaitinfo.c Simplify Linux sig{timed}wait{info} implementations 2017-11-06 17:37:57 -02:00
sizes.h
socket.c
socketcall.h
socketpair.c
spawni.c posix: Do not use WNOHANG in waitpid call for Linux posix_spawn 2017-10-23 13:31:26 -02:00
speed.c
splice.c
statfs64.c
statvfs.c Mark __internal_statvfs[64] with attribute_hidden [BZ #18822] 2017-10-01 15:08:32 -07:00
statvfs64.c Mark __internal_statvfs[64] with attribute_hidden [BZ #18822] 2017-10-01 15:08:32 -07:00
sync_file_range.c
syscall-names.list Update kernel version in syscall-names.list to 4.14. 2017-11-16 17:51:54 +00:00
syscalls.list Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
sysconf.c Consolidate non cancellable close call 2017-08-18 18:38:55 -03:00
sysctl.c
sysctl.mk
sysdep-cancel.h Linux: Consolidate {RTLD_}SINGLE_THREAD_P definition 2017-10-11 14:27:24 -03:00
sysdep-vdso.h
sysdep.h
syslog.c
system.c
tcdrain.c
tcflow.c
tcflush.c
tcgetattr.c Hide internal __tcgetattr function [BZ #18822] 2017-10-01 17:48:24 -07:00
tcgetpgrp.c
tcsendbrk.c
tcsetattr.c
tcsetpgrp.c
tee.c
termio.h
test-errno-linux.c test-errno-linux: quotactl can fail with EPERM in containers 2017-11-02 13:55:51 +01:00
time.c
timer_create.c
timer_delete.c
timer_getoverr.c
timer_gettime.c
timer_routines.c
timer_settime.c
times.c
timespec_get.c
truncate.c
truncate64.c
tst-affinity-pid.c
tst-affinity.c
tst-align-clone.c
tst-clone.c
tst-clone2.c
tst-clone3.c
tst-fallocate-common.c
tst-fallocate.c
tst-fallocate64.c
tst-fanotify.c
tst-getpid1.c
tst-memfd_create.c Linux: Add memfd_create system call wrapper 2017-11-23 10:00:40 +01:00
tst-personality.c
tst-quota.c
tst-setgetname.c
tst-signal-numbers.sh
tst-skeleton-affinity.c
tst-skeleton-thread-affinity.c
tst-sync_file_range.c
tst-syscall-list.sh <bits/syscall.h>: Use an arch-independent system call list on Linux 2017-08-28 11:58:52 +02:00
tst-sysconf-iov_max-uapi.c sysconf: Fix missing definition of UIO_MAXIOV on Linux [BZ #22321] 2017-10-20 04:10:15 +02:00
tst-sysconf-iov_max.c sysconf: Fix missing definition of UIO_MAXIOV on Linux [BZ #22321] 2017-10-20 04:10:15 +02:00
tst-thread-affinity-pthread.c
tst-thread-affinity-pthread2.c
tst-thread-affinity-sched.c
tst-ttyname.c tst-ttyname: Fix namespace setup for Fedora 2017-11-18 14:34:46 +01:00
ttyname.c linux ttyname{_r}: Don't bail prematurely [BZ #22145] 2017-11-15 20:47:12 +01:00
ttyname.h linux ttyname{_r}: Make tty checks consistent 2017-11-15 20:47:07 +01:00
ttyname_r.c linux ttyname{_r}: Don't bail prematurely [BZ #22145] 2017-11-15 20:47:12 +01:00
ualarm.c
umount.S
umount2.S
unlockpt.c
updwtmp.c
ustat.c
utimensat.c
utimes.c
utmp_file.c
vfork.c
vmsplice.c
wait.c
wait3.c
waitid.c
waitpid.c Consolidate non cancellable waitpid call 2017-08-21 15:37:45 -03:00
write.c Consolidate non cancellable write call 2017-08-18 10:53:47 -03:00
writev.c Hide __readv and __writev [BZ #18822] 2017-10-01 15:54:10 -07:00
xmknod.c
xmknodat.c
xstat.c
xstat64.c
xstatconv.c
xstatconv.h