fix building with newer glibc

Submitted by Adrian Reber on June 29, 2017, 2:19 p.m.

Details

Message ID 20170629141932.5605-1-adrian@lisas.de
State Accepted
Series "fix building with newer glibc"
Headers show

Commit Message

Adrian Reber June 29, 2017, 2:19 p.m.
From: Adrian Reber <areber@redhat.com>

Newer glibc releases have removed SIGUNUSED from bits/signum.h which
breaks building criu on those systems:

https://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=8082d91e1c449e0cb137468b731004a5e605c8c6

SIGSYS returns the same value as SIGUNUSED and testing has shown
that criu still successfully completes zdtm with this patch.

Signed-off-by: Adrian Reber <areber@redhat.com>
Reviewed-by: Dmitry Safonov <dsafonov@virtuozzo.com>
---
 criu/cr-restore.c            | 1 -
 test/zdtm/static/pthread01.c | 2 +-
 2 files changed, 1 insertion(+), 2 deletions(-)

Patch hide | download patch | download mbox

diff --git a/criu/cr-restore.c b/criu/cr-restore.c
index 2c505f6e..eaaed416 100644
--- a/criu/cr-restore.c
+++ b/criu/cr-restore.c
@@ -1062,7 +1062,6 @@  static void zombie_prepare_signals(void)
 		(1 << SIGPOLL)	|\
 		(1 << SIGIO)	|\
 		(1 << SIGSYS)	|\
-		(1 << SIGUNUSED)|\
 		(1 << SIGSTKFLT)|\
 		(1 << SIGPWR)	 \
 	)
diff --git a/test/zdtm/static/pthread01.c b/test/zdtm/static/pthread01.c
index 52f849c0..2520fcfe 100644
--- a/test/zdtm/static/pthread01.c
+++ b/test/zdtm/static/pthread01.c
@@ -43,7 +43,7 @@  static char *decode_signal(const sigset_t *s, char *buf)
 	COLLECT(SIGTERM); COLLECT(SIGSTKFLT); COLLECT(SIGCHLD); COLLECT(SIGCONT); COLLECT(SIGSTOP);
 	COLLECT(SIGTSTP); COLLECT(SIGTTIN); COLLECT(SIGTTOU); COLLECT(SIGURG); COLLECT(SIGXCPU);
 	COLLECT(SIGXFSZ); COLLECT(SIGVTALRM); COLLECT(SIGPROF); COLLECT(SIGWINCH); COLLECT(SIGIO);
-	COLLECT(SIGPOLL); COLLECT(SIGPWR); COLLECT(SIGSYS); COLLECT(SIGUNUSED);
+	COLLECT(SIGPOLL); COLLECT(SIGPWR); COLLECT(SIGSYS);
 #undef COLLECT
 
 	return buf;