From 515d25281c0e039dc1211d3337ae3d293070a3e0 Mon Sep 17 00:00:00 2001 From: Florian Festi Date: Fri, 5 Jul 2024 13:24:16 +0200 Subject: [PATCH] Sort output for test case to avoid race condition As the test uses fork() the processes can write out the lines in different orders Resolves: #3106 --- tests/rpmmacro.at | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/rpmmacro.at b/tests/rpmmacro.at index a31242e9c6..372cfa3edd 100644 --- a/tests/rpmmacro.at +++ b/tests/rpmmacro.at @@ -1440,7 +1440,7 @@ nil No such file or directory 2.0 []) RPMTEST_CHECK([ -runroot_other rpmlua -e 'pid = posix.fork(); if pid == 0 then a,b,c=rpm.redirect2null(-1); print(string.format("%s\t%s\t%s", a,b,c)); io.flush() else posix.wait(pid) end' +runroot_other rpmlua -e 'pid = posix.fork(); if pid == 0 then a,b,c=rpm.redirect2null(-1); print(string.format("%s\t%s\t%s", a,b,c)); io.flush() else posix.wait(pid) end' 2> >(sort >&2) ], [0], [nil Bad file descriptor 9.0