sbopkg, slackpkg, slapt: Don't leak local $i.
This commit is contained in:
parent
8a63dc2589
commit
4e79c13d0d
@ -38,8 +38,8 @@ _sbopkg()
|
||||
return 0
|
||||
fi
|
||||
|
||||
local config="/etc/sbopkg/sbopkg.conf"
|
||||
|
||||
local i config
|
||||
config="/etc/sbopkg/sbopkg.conf"
|
||||
for (( i=${#words[@]}-1; i>0; i-- )); do
|
||||
if [[ "${words[i]}" == -f ]]; then
|
||||
config="${words[i+1]}"
|
||||
|
@ -50,7 +50,7 @@ _slackpkg()
|
||||
fi
|
||||
. "$config"
|
||||
|
||||
local action
|
||||
local i action
|
||||
for (( i=1; i<${#words[@]}; i++ )); do
|
||||
if [[ "${words[i]}" != -* ]]; then
|
||||
action="${words[i]}"
|
||||
|
@ -29,7 +29,7 @@ _slapt_get()
|
||||
return 0
|
||||
fi
|
||||
|
||||
local t
|
||||
local i t
|
||||
# search for last action (--install|--install-set|--remove|--show|--filelist)
|
||||
for (( i=${#words[@]}-1; i>0; i-- )); do
|
||||
if [[ ${words[i]} == -@(i|-install|-show) ]]; then
|
||||
@ -90,7 +90,7 @@ _slapt_src()
|
||||
return 0
|
||||
fi
|
||||
|
||||
local t
|
||||
local i t
|
||||
# search for last action (-i|-w|-b|-f)
|
||||
for (( i=${#words[@]}-1; i>0; i-- )); do
|
||||
if [[ ${words[i]} == -@(i|w|f|b|-install|-show|-build|-fetch) ]]; then
|
||||
|
Loading…
x
Reference in New Issue
Block a user