From 6e7b3e4cbaceee024c821ca55e1c256c9ddd6760 Mon Sep 17 00:00:00 2001 From: Sebastian Brzezinka Date: Tue, 22 Nov 2022 10:27:30 +0100 Subject: [PATCH] SC2048: Use "${array[@]}" (with quotes) to prevent whitespace problems. Signed-off-by: Sebastian Brzezinka Change-Id: I64473e4904c82fa06d41e8a02d56070ebf966adc Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/15559 Tested-by: SPDK CI Jenkins Reviewed-by: Jim Harris Reviewed-by: Tomasz Zawadzki Reviewed-by: Michal Berger --- scripts/arm_cross_compile.sh | 2 +- test/interrupt/reactor_set_interrupt.sh | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/arm_cross_compile.sh b/scripts/arm_cross_compile.sh index 212263922..c3fc54d46 100755 --- a/scripts/arm_cross_compile.sh +++ b/scripts/arm_cross_compile.sh @@ -318,6 +318,6 @@ get_cc_toolchain cross_compile_packages=(numa uuid crypto_ssl libaio ncurses cunit isal dpdk spdk) -for index in ${cross_compile_packages[*]}; do +for index in "${cross_compile_packages[@]}"; do cross_compile_$index done diff --git a/test/interrupt/reactor_set_interrupt.sh b/test/interrupt/reactor_set_interrupt.sh index a7516331e..c3b8a4512 100755 --- a/test/interrupt/reactor_set_interrupt.sh +++ b/test/interrupt/reactor_set_interrupt.sh @@ -29,10 +29,10 @@ function reactor_set_intr_mode() { if [ "$without_thd"x != x ]; then # Schedule all spdk_threads to reactor 1 - for i in ${thd0_ids[*]}; do + for i in "${thd0_ids[@]}"; do $rpc_py thread_set_cpumask -i $i -m $r1_mask done - for i in ${thd2_ids[*]}; do + for i in "${thd2_ids[@]}"; do $rpc_py thread_set_cpumask -i $i -m $r1_mask done fi @@ -48,7 +48,7 @@ function reactor_set_intr_mode() { $rpc_py --plugin interrupt_plugin reactor_set_interrupt_mode 2 if [ "$without_thd"x != x ]; then # Schedule spdk_threads in thd2_ids back to reactor 2 - for i in ${thd2_ids[*]}; do + for i in "${thd2_ids[@]}"; do $rpc_py thread_set_cpumask -i $i -m $r2_mask done fi @@ -59,7 +59,7 @@ function reactor_set_intr_mode() { $rpc_py --plugin interrupt_plugin reactor_set_interrupt_mode 0 if [ "$without_thd"x != x ]; then # Schedule spdk_threads in thd2_ids back to reactor 0 - for i in ${thd0_ids[*]}; do + for i in "${thd0_ids[@]}"; do $rpc_py thread_set_cpumask -i $i -m $r0_mask done fi