[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Test suite failure in new snapshot
From: |
Jim Meyering |
Subject: |
Re: Test suite failure in new snapshot |
Date: |
Sat, 29 Mar 2008 19:21:07 +0100 |
Jim Meyering <address@hidden> wrote:
> Sven Joachim <address@hidden> wrote:
>> I got an error in `make check' in this snapshot:
>> Here are the contents of selinux.log:
>>
>> FAIL: selinux.log (exit: 1)
>> --- out 2008-03-29 17:48:48.000000000 +0100
>> +++ exp 2008-03-29 17:48:48.000000000 +0100
>> @@ -1 +1 @@
>> -mkdir: failed to set default file creation context to
>> `invalid-selinux-context': No such file or directory
>> +mkdir: failed to set default file creation context to
>> `invalid-selinux-context':
> ...
>
> Thanks for the quick feedback!
>
> That's odd.
> But it's easy to work around. Patch below, but before I apply
> it for good, I'd like to understand why it is happening.
>
> What type of system are you using?
> Kernel? Which version of libselinux?
>
> Please run this:
>
> strace -o log ./mkdir -Z jdkdjkdj foo
>
> and post the contents of the resulting "log" file.
>
> -----------------------
>
> avoid spurious failure of new test on/when ???
> * tests/mkdir/selinux: Also accept ENOENT.
> Reported by Sven Joachim.
Whoops. Missing backslashes.
Here's a patch that actually has a chance of working ;-)
diff --git a/tests/mkdir/selinux b/tests/mkdir/selinux
index c0fc201..f8aeace 100755
--- a/tests/mkdir/selinux
+++ b/tests/mkdir/selinux
@@ -37,8 +37,11 @@ for cmd_w_arg in 'mkdir dir' 'mknod b p' 'mkfifo f'; do
set $cmd_w_arg; cmd=$1
echo "$cmd: $msg" > exp || fail=1
- # Some systems fail with ENOTSUP, some with EINVAL.
- sed 's/ Invalid argument$//;s/ Operation not supported$//' out > k || fail=1
+ # Some systems fail with ENOTSUP, or EINVAL, or even ENOENT.
+ sed \
+ -e 's/ Invalid argument$//' \
+ -e 's/ Operation not supported$//' \
+ -e 's/ No such file or directory$//' out > k || fail=1
mv k out || fail=1
compare out exp || fail=1
done
--
1.5.5.rc1.13.g79388