lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 23 Jan 2024 14:17:34 +0100
From: Davide Caratti <dcaratti@...hat.com>
To: Pedro Tammela <pctammela@...atatu.com>
Cc: netdev@...r.kernel.org, jhs@...atatu.com, xiyou.wangcong@...il.com, 
	jiri@...nulli.us, shuah@...nel.org, kuba@...nel.org, vladimir.oltean@....com, 
	edumazet@...gle.com, pabeni@...hat.com, linux-kselftest@...r.kernel.org
Subject: Re: [PATCH net-next 2/4] selftests: tc-testing: check if 'jq' is
 available in taprio script

hi Pedro,

On Tue, Jan 23, 2024 at 1:28 PM Pedro Tammela <pctammela@...atatu.com> wrote:
>
> If 'jq' is not available the taprio tests that use this script will
> run forever. Check if it exists before entering the while loop.
>
> Signed-off-by: Pedro Tammela <pctammela@...atatu.com>
> ---
>  .../selftests/tc-testing/scripts/taprio_wait_for_admin.sh    | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/tools/testing/selftests/tc-testing/scripts/taprio_wait_for_admin.sh b/tools/testing/selftests/tc-testing/scripts/taprio_wait_for_admin.sh
> index f5335e8ad6b4..68f2c6eaa802 100755
> --- a/tools/testing/selftests/tc-testing/scripts/taprio_wait_for_admin.sh
> +++ b/tools/testing/selftests/tc-testing/scripts/taprio_wait_for_admin.sh
> @@ -3,6 +3,11 @@
>  TC="$1"; shift
>  ETH="$1"; shift
>
> +if ! command -v jq &> /dev/null; then
> +    echo "Please install jq"
> +    exit 1
> +fi
> +

nit: what about returning $KSFT_SKIP (that is 4) if jq is not there?
so the test does not fail.
thanks!
-- 
davide


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ