diff options
author | Jan Lindström <jan.lindstrom@mariadb.com> | 2018-08-29 19:30:03 +0300 |
---|---|---|
committer | Jan Lindström <jan.lindstrom@mariadb.com> | 2018-08-29 19:30:03 +0300 |
commit | 104089e182f31524d85409bd59f1889e36d4636a (patch) | |
tree | 164e1cd0126e18312d2100d75dca5e428af8f1be /scripts | |
parent | 6c588c92a9b17c5478c60713c7d5b17a38044295 (diff) | |
download | mariadb-git-104089e182f31524d85409bd59f1889e36d4636a.tar.gz |
MDEV-15512 - Fix sh parse error when [sst] config value has spaces.
Merged https://github.com/MariaDB/server/pull/617 authored by
Colin Mollenhour.
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/wsrep_sst_common.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/wsrep_sst_common.sh b/scripts/wsrep_sst_common.sh index 7f1f44d0cdb..bc26cec6d83 100644 --- a/scripts/wsrep_sst_common.sh +++ b/scripts/wsrep_sst_common.sh @@ -277,8 +277,8 @@ parse_cnf() reval=$($MY_PRINT_DEFAULTS "${group}" | awk -v var="${var}" 'BEGIN { OFS=FS="=" } { gsub(/_/,"-",$1); if ( $1=="--"var) lastval=substr($0,length($1)+2) } END { print lastval}') # use default if we haven't found a value - if [ -z $reval ]; then - [ -n $3 ] && reval=$3 + if [ -z "$reval" ]; then + [ -n "$3" ] && reval=$3 fi echo $reval } |