]> granicus.if.org Git - strace/commit
tests: robustify ipc_msgbuf.test against broken libc
authorDmitry V. Levin <ldv@altlinux.org>
Sat, 2 Dec 2017 22:01:34 +0000 (22:01 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Sun, 3 Dec 2017 00:25:43 +0000 (00:25 +0000)
commita6e30c11d24c3387d60df668d951ea5af390ea11
treeb57b91d311b6c3e68f9801dff20fc45fe0815e9b
parent5f61f158c3680e003b81bb9e311358ab842b0de1
tests: robustify ipc_msgbuf.test against broken libc

glibc between commits glibc-2.25~130 and glibc-2.26~740 had broken
msgctl(IPC_RMID) on hppa: this operation always failed with EINVAL
because of inappropriate use of IPC_64 flag.  Similar issues were
fixed on other niche architectures.  Let's workaround these issues
by skipping the test in case of msgctl(IPC_RMID) failure.

* tests/ipc_msgbuf.c (cleanup): Change return type to int,
return 77 in case of msgctl(IPC_RMID) failure.
(main): Explicitly invoke cleanup() at the end.
tests/ipc_msgbuf.c