summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorRuediger Meier2018-03-07 10:40:23 +0100
committerKarel Zak2018-03-07 11:50:05 +0100
commiteb10dbc159dd0d7dfd7c213c0351eef6e17d45ef (patch)
tree07dc3adcbab0c4cc865d822796b0d057a9b89960 /tests
parentlibmount: fix fs pattern usage in mount --all (diff)
downloadkernel-qcow2-util-linux-eb10dbc159dd0d7dfd7c213c0351eef6e17d45ef.tar.gz
kernel-qcow2-util-linux-eb10dbc159dd0d7dfd7c213c0351eef6e17d45ef.tar.xz
kernel-qcow2-util-linux-eb10dbc159dd0d7dfd7c213c0351eef6e17d45ef.zip
uuidd: don't truncate long socket paths
This was the error uuidd: couldn't bind unix socket /var/tmp/portage/sys-apps/util-linux-2.31.1/work/util-linux-2.31.1-abi_x86_64.amd64/tests/output/uuid/uuiddkOcTUuoZ7kaP3: Address already in use because the socket path was truncated to 108 chars which was luckily an existing directory. Now we abort early with "uuidd: socket name too long: ... " Reported-by: Thomas Deutschmann <whissi@gentoo.org> Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
Diffstat (limited to 'tests')
-rwxr-xr-xtests/ts/uuid/uuidd3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/ts/uuid/uuidd b/tests/ts/uuid/uuidd
index 17cf29d06..16dc45e3f 100755
--- a/tests/ts/uuid/uuidd
+++ b/tests/ts/uuid/uuidd
@@ -23,7 +23,8 @@ ts_check_test_command "$TS_CMD_UUIDD"
OUTPUT_FILE="$(mktemp "${TS_OUTDIR}/uuiddXXXXXXXXXXXXX")"
UUIDD_PID="$(mktemp -u "${TS_OUTDIR}/uuiddXXXXXXXXXXXXX")"
-UUIDD_SOCKET="$(mktemp -u "${TS_OUTDIR}/uuiddXXXXXXXXXXXXX")"
+# socket path must be short (SIZEOF_SOCKADDR_UN_SUN_PATH 108)
+UUIDD_SOCKET=$(mktemp "/tmp/ultest-$TS_COMPONENT-$TS_TESTNAME-socketXXXXXX")
$TS_CMD_UUIDD -p "$UUIDD_PID" -s "$UUIDD_SOCKET"
if [ $? -ne 0 ]; then