X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=shell-completion%2Fbash%2Fsystemd-coredumpctl;h=805e84824e384882e1307bb81aa0543193558093;hp=4bbece7347a09d9e5294aee5af29260c01f2d9e2;hb=b68b76897aca23f613afdc39a760992c711a7671;hpb=d611dadcc74db10ba533ee6859308f5fc505aee1;ds=inline diff --git a/shell-completion/bash/systemd-coredumpctl b/shell-completion/bash/systemd-coredumpctl index 4bbece734..805e84824 100644 --- a/shell-completion/bash/systemd-coredumpctl +++ b/shell-completion/bash/systemd-coredumpctl @@ -18,9 +18,10 @@ # along with systemd; If not, see . __contains_word () { - local word=$1; shift - for w in $*; do [[ $w = $word ]] && return 0; done - return 1 + local w word=$1; shift + for w in "$@"; do + [[ $w = "$word" ]] && return + done } __journal_fields=(MESSAGE{,_ID} PRIORITY CODE_{FILE,LINE,FUNC}