Re: An obscure problem with v2.37 make check

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jun 17, 2021 at 12:00 PM Karel Zak <kzak@xxxxxxxxxx> wrote:
> > One solution to this problem may be to test for the existence of the file
> > before running 'stat' similar to the tests for programs like 'touch' and
>
> Sounds good. Please, send patch.

Bruce, Karel,

something like this?

util-linux$ git diff
diff --git a/tests/ts/lsns/ioctl_ns b/tests/ts/lsns/ioctl_ns
index e91f6743f..b8f35e2e5 100755
--- a/tests/ts/lsns/ioctl_ns
+++ b/tests/ts/lsns/ioctl_ns
@@ -24,6 +24,9 @@ ts_init "$*"
 # ts_skip_nonroot
 grep -q '#define HAVE_LINUX_NSFS_H' ${top_builddir}/config.h ||
ts_skip "no ioctl_ns support"

+[ -a /proc/self/ns/user ] || ts_skip "no USER namespace kernel support"
+[ -a /proc/self/ns/pid ] || ts_skip "no PID namespace kernel support"
+
 ts_check_test_command "$TS_CMD_LSNS"
 ts_check_test_command "$TS_CMD_UNSHARE"
 ts_check_prog "stat"



[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux