From: Jim Meyering Date: Sun, 14 Jun 2009 12:43:16 +0000 (+0200) Subject: use a local var: more readable X-Git-Tag: v7.5~93 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c0d82452883a10911c9cbc69c84144d99b7e6b08;p=thirdparty%2Fcoreutils.git use a local var: more readable --- diff --git a/tests/test-lib.sh b/tests/test-lib.sh index d99e3a9662..60e92d3c62 100644 --- a/tests/test-lib.sh +++ b/tests/test-lib.sh @@ -124,7 +124,8 @@ uid_is_privileged_() get_process_status_() { - sed -n '/^State:[ ]*\([[:alpha:]]\).*/s//\1/p' /proc/$1/status + local pid=$1 + sed -n '/^State:[ ]*\([[:alpha:]]\).*/s//\1/p' /proc/$pid/status } # Convert an ls-style permission string, like drwxr----x and -rw-r-x-wx