From 44e21ae30d0240bf719ca9cf1e0d383aab8ab6fe Mon Sep 17 00:00:00 2001 From: "Dmitry V. Levin" Date: Wed, 22 Aug 2018 20:38:27 +0000 Subject: [PATCH] tests: workaround systemd-nspawn habit of disabling unimplemented syscalls * tests/nsyscalls.c (test_syscall): Do not assume that unimplemented syscalls always fail with ENOSYS. --- tests/nsyscalls.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/nsyscalls.c b/tests/nsyscalls.c index 681fb315..e2ebbf99 100644 --- a/tests/nsyscalls.c +++ b/tests/nsyscalls.c @@ -82,18 +82,18 @@ test_syscall(const unsigned long nr) #ifdef LINUX_MIPSO32 printf("syscall(%#lx, %#lx, %#lx, %#lx, %#lx, %#lx, %#lx)" - " = %ld ENOSYS (%m)\n", nr | SYSCALL_BIT, - a[0], a[1], a[2], a[3], a[4], a[5], rc); + " = %s\n", nr | SYSCALL_BIT, + a[0], a[1], a[2], a[3], a[4], a[5], sprintrc(rc)); #else printf("syscall_%#lx(%#llx, %#llx, %#llx, %#llx, %#llx, %#llx)" - " = %ld ENOSYS (%m)\n", nr | SYSCALL_BIT, + " = %s\n", nr | SYSCALL_BIT, (unsigned long long) a[0], (unsigned long long) a[1], (unsigned long long) a[2], (unsigned long long) a[3], (unsigned long long) a[4], (unsigned long long) a[5], - rc); + sprintrc(rc)); #endif } -- 2.40.0