diff --git a/README.md b/README.md index 814ceb6..5ed3d34 100644 --- a/README.md +++ b/README.md @@ -1103,7 +1103,7 @@ basename() { # Usage: basename "path" ["suffix"] local tmp - tmp=${1%${1##*[!/]}} + tmp=${1%"${1##*[!/]}"} tmp=${tmp##*/} tmp=${tmp%"${2/"$tmp"}"} diff --git a/manuscript/chapter5.txt b/manuscript/chapter5.txt index 4be6b11..09282b2 100644 --- a/manuscript/chapter5.txt +++ b/manuscript/chapter5.txt @@ -42,7 +42,7 @@ basename() { # Usage: basename "path" ["suffix"] local tmp - tmp=${1%${1##*[!/]}} + tmp=${1%"${1##*[!/]}"} tmp=${tmp##*/} tmp=${tmp%"${2/"$tmp"}"}