]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/test/test-execute.c
test-execute: check if private directories have bad permissions before running test_e...
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 4 Sep 2020 16:02:57 +0000 (18:02 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 4 Sep 2020 16:45:44 +0000 (18:45 +0200)
commitcced2b98efcf60f9dce573451ff637bb8227d90b
treef08479a0819ebd6a8f815bc130b06fba1c00680f
parent9978e631cdfac4d4ac9b38e9496b9df1bd042b60
test-execute: check if private directories have bad permissions before running test_exec_dynamicuser()

If the directory (/var/lib/private is most likely) has borked permissions, the
test will fail with a cryptic message and EXIT_STATE_DIRECTORY or similar. The
message from the child with more details gets lost somewhere. Let's avoid running
the test in that case and provide a simple error message instead.

E.g. systemd-238-12.git07f8cd5.fc28.ppc64 (which I encountered on a test machine)
has /var/lib/private with 0755.
src/test/test-execute.c