From: Shengyu Li <shengyu.li.evgeny@gmail.com>
To: shuah@kernel.org
Cc: linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org,
Shengyu Li <shengyu.li.evgeny@gmail.com>
Subject: [PATCH] selftest/safesetid: Fix uncaught return value
Date: Wed, 1 May 2024 05:28:13 +0800 [thread overview]
Message-ID: <20240430212813.11910-1-shengyu.li.evgeny@gmail.com> (raw)
This patch captures the return value of the ./safesetid-test execution
by assigning it to the variable errcode. This change ensures that the
script properly handles the exit status of the safesetid-test.
Signed-off-by: Shengyu Li <shengyu.li.evgeny@gmail.com>
---
tools/testing/selftests/safesetid/safesetid-test.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/testing/selftests/safesetid/safesetid-test.sh b/tools/testing/selftests/safesetid/safesetid-test.sh
index e4fdce675c54..0ebc6ddc4b6c 100755
--- a/tools/testing/selftests/safesetid/safesetid-test.sh
+++ b/tools/testing/selftests/safesetid/safesetid-test.sh
@@ -19,6 +19,7 @@ main_function()
{
check_root
./safesetid-test
+ errcode=$?
}
main_function
--
2.25.1
reply other threads:[~2024-04-30 21:28 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240430212813.11910-1-shengyu.li.evgeny@gmail.com \
--to=shengyu.li.evgeny@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).