diff options
| author | Sami Kerola <kerolasa@iki.fi> | 2017-06-30 23:13:58 +0100 |
|---|---|---|
| committer | Sami Kerola <kerolasa@iki.fi> | 2017-07-15 22:05:42 +0100 |
| commit | abbcec4fc9c8d7fb835b4eafd1bc9d82acbf0056 (patch) | |
| tree | ce554d5e4e09146e5df0cfaa6c014afbf9b09357 /bash-completion/lsipc | |
| parent | 5d70066c1a8d92d10202f9a1e0ea9eb9feb1c6a5 (diff) | |
| download | util-linux-abbcec4fc9c8d7fb835b4eafd1bc9d82acbf0056.tar.gz | |
bash-completion: make completions to work when bash set -u is in use
User who want to avoid refering to none-existing variables got earlier the
following error.
$ set -u
$ findmnt --output <tab>bash: OUTPUT: unbound variable
Here is short explanation of this setting.
$ help set
-u Treat unset variables as an error when substituting.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'bash-completion/lsipc')
| -rw-r--r-- | bash-completion/lsipc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bash-completion/lsipc b/bash-completion/lsipc index ffe44b7d1f..a40fe42860 100644 --- a/bash-completion/lsipc +++ b/bash-completion/lsipc @@ -35,7 +35,7 @@ _lsipc_module() " for WORD in $OUTPUT_ALL; do if ! [[ $prefix == *"$WORD"* ]]; then - OUTPUT="$WORD $OUTPUT" + OUTPUT="$WORD ${OUTPUT:-""}" fi done compopt -o nospace |
