modules/programs: sane-sandboxed: fix normPath handling of paths containing special characters like [
This commit is contained in:
@@ -91,7 +91,8 @@ normPath() {
|
|||||||
# and we push nothing to _npComps,
|
# and we push nothing to _npComps,
|
||||||
# but we're guaranteed to make progress.
|
# but we're guaranteed to make progress.
|
||||||
_npThisComp="${_npUnparsed%%/*}"
|
_npThisComp="${_npUnparsed%%/*}"
|
||||||
_npUnparsed="${_npUnparsed/$_npThisComp}"
|
_npThisLen="${#_npThisComp}"
|
||||||
|
_npUnparsed="${_npUnparsed:$_npThisLen}"
|
||||||
if [ "$_npThisComp" = ".." ]; then
|
if [ "$_npThisComp" = ".." ]; then
|
||||||
# "go up" path component => delete the leaf dir (if any)
|
# "go up" path component => delete the leaf dir (if any)
|
||||||
if [ ${#_npComps[@]} -ne 0 ]; then
|
if [ ${#_npComps[@]} -ne 0 ]; then
|
||||||
|
Reference in New Issue
Block a user