]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
selftests: net: really check for bg process completion
authorPaolo Abeni <pabeni@redhat.com>
Tue, 5 Nov 2024 18:23:51 +0000 (19:23 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Dec 2024 12:53:23 +0000 (13:53 +0100)
[ Upstream commit 52ed077aa6336dbef83a2d6d21c52d1706fb7f16 ]

A recent refactor transformed the check for process completion
in a true statement, due to a typo.

As a result, the relevant test-case is unable to catch the
regression it was supposed to detect.

Restore the correct condition.

Fixes: 691bb4e49c98 ("selftests: net: avoid just another constant wait")
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Link: https://patch.msgid.link/0e6f213811f8e93a235307e683af8225cc6277ae.1730828007.git.pabeni@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
tools/testing/selftests/net/pmtu.sh

index 5175c0c83a238c1193ff3fede69dec85885fe36a..d5af6099d6477d2a2d6856271dbc104c55b31274 100755 (executable)
@@ -2062,7 +2062,7 @@ check_running() {
        pid=${1}
        cmd=${2}
 
-       [ "$(cat /proc/${pid}/cmdline 2>/dev/null | tr -d '\0')" = "{cmd}" ]
+       [ "$(cat /proc/${pid}/cmdline 2>/dev/null | tr -d '\0')" = "${cmd}" ]
 }
 
 test_cleanup_vxlanX_exception() {