From 15c7e8bd8c6ee7f57d18de6fb8f931059200dd4c Mon Sep 17 00:00:00 2001 From: Arfrever Frehtes Taifersar Arahesis Date: Sat, 30 Apr 2011 18:30:29 +0200 Subject: install_qa_check(): Simplify code and make 'l' a local variable. --- bin/misc-functions.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/misc-functions.sh b/bin/misc-functions.sh index c3109981d..b28b73fff 100755 --- a/bin/misc-functions.sh +++ b/bin/misc-functions.sh @@ -193,10 +193,10 @@ install_qa_check() { # 3) Null paths are banned because the loader will search $PWD when # it finds null paths. local forbidden_dirs="${PORTAGE_BUILDDIR}" - if [[ -n "$ROOT" ]] && [[ "$ROOT" != "/" ]]; then - forbidden_dirs="${forbidden_dirs} ${ROOT}" + if [[ -n "${ROOT}" && "${ROOT}" != "/" ]]; then + forbidden_dirs+=" ${ROOT}" fi - local dir="" rpath_files=$(scanelf -F '%F:%r' -qBR "${D}") + local dir l rpath_files=$(scanelf -F '%F:%r' -qBR "${D}") f="" for dir in ${forbidden_dirs}; do for l in $(echo "${rpath_files}" | grep -E ":${dir}|::|: "); do -- cgit v1.2.3-1-g7c22