Fix quoting bug in _lp_upwards_find #255

Thanks to @bkc for the pointer to this issue and a partial fix.
This commit is contained in:
Olivier Mengué 2013-12-27 17:36:36 +01:00
parent a0509ac15a
commit 1aca2d7e3d

View File

@ -827,10 +827,10 @@ _lp_upwards_find()
while [[ "$PWD" != "/" ]] ; do
# See if it's in the current directory.
local found=$(find "$PWD"/ -maxdepth 1 -name "$@" 2> /dev/null)
local found="$(find "$PWD"/ -maxdepth 1 -name "$@" 2> /dev/null)"
# If it is, then echo the path (or anything), and return.
if [[ -n found ]] ; then
if [[ -n "$found" ]] ; then
echo $found
return
fi