File tree Expand file tree Collapse file tree 1 file changed +11
-10
lines changed
Expand file tree Collapse file tree 1 file changed +11
-10
lines changed Original file line number Diff line number Diff line change @@ -1786,7 +1786,7 @@ _included_ssh_config_files()
17861786{
17871787 (( $# < 1 )) &&
17881788 echo " bash_completion: $FUNCNAME : missing mandatory argument CONFIG" >&2
1789- local configfile i f
1789+ local configfile i files f
17901790 configfile=$1
17911791
17921792 local IFS=$' \t\n ' reset=$( shopt -po noglob)
@@ -1809,15 +1809,16 @@ _included_ssh_config_files()
18091809 fi
18101810 __expand_tilde_by_ref i
18111811 # In case the expanded variable contains multiple paths
1812- set +o noglob
1813- for f in $i ; do
1814- if [[ -r $f ]]; then
1815- config+=(" $f " )
1816- # The Included file is processed to look for Included files in itself
1817- _included_ssh_config_files $f
1818- fi
1819- done
1820- $reset
1812+ _comp_expand_glob files ' $i'
1813+ if (( ${# files[@]} )) ; then
1814+ for f in " ${files[@]} " ; do
1815+ if [[ -r $f ]]; then
1816+ config+=(" $f " )
1817+ # The Included file is processed to look for Included files in itself
1818+ _included_ssh_config_files $f
1819+ fi
1820+ done
1821+ fi
18211822 done
18221823} # _included_ssh_config_files()
18231824
You can’t perform that action at this time.
0 commit comments