1 Star 0 Fork 15

wangzhiqiang / sg3_utils

forked from src-openEuler / sg3_utils 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0002-bugfix-sg3_utils-fix-syntax-error.patch 1.26 KB
一键复制 编辑 原始数据 按行查看 历史
Wenchao Hao 提交于 2022-07-01 11:40 . fix syntax error introduced by patch
From 1d2cf4e2a477646b212b25d6d6be5fee99e20bdb Mon Sep 17 00:00:00 2001
From: sunshihao <sunshihao@huawei.com>
Date: Thu, 16 Apr 2020 10:53:25 +0800
Subject: [PATCH 3/4] bugfix-sg3_utils-fix-syntax-error
Signed-off-by: Wenchao Hao <haowenchao@huawei.com>
---
scripts/rescan-scsi-bus.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/rescan-scsi-bus.sh b/scripts/rescan-scsi-bus.sh
index b1cbebc..5f867c4 100755
--- a/scripts/rescan-scsi-bus.sh
+++ b/scripts/rescan-scsi-bus.sh
@@ -289,7 +289,7 @@ testonline ()
print_and_scroll_back "$host:$channel:$id:$lun $SGDEV ($RMB) "
[ $RC = 2 ] && [ "$RMB" = "1" ] && break
done
- if [ $ctr != 0 ] ; then
+ if [ "$ctr" != 0 ] ; then
white_out
fi
# echo -e "\e[A\e[A\e[A${yellow}Test existence of $SGDEV = $RC ${norm} \n\n\n"
@@ -1283,7 +1283,7 @@ if [ "$sync" = 2 ] ; then
echo "Syncing file systems"
sync
fi
-if [ -w /sys/module/scsi_mod/parameters/default_dev_flags ] && [ $scan_flags != 0 ] ; then
+if [ -w /sys/module/scsi_mod/parameters/default_dev_flags ] && [ "$scan_flags" != 0 ] ; then
OLD_SCANFLAGS=$(cat /sys/module/scsi_mod/parameters/default_dev_flags)
NEW_SCANFLAGS=$((OLD_SCANFLAGS|scan_flags))
if [ "$OLD_SCANFLAGS" != "$NEW_SCANFLAGS" ] ; then
--
2.35.3
1
https://gitee.com/foolstrong/sg3_utils.git
git@gitee.com:foolstrong/sg3_utils.git
foolstrong
sg3_utils
sg3_utils
master

搜索帮助