From 8d61ae0b759b075d9b903e1ae5069430a66d8a92 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Tue, 18 Jun 2013 21:02:59 +0200 Subject: derp MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/ArgParser.java | 2 +- src/argparser.bash | 2 +- src/argparser.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ArgParser.java b/src/ArgParser.java index e75ba91..798f780 100644 --- a/src/ArgParser.java +++ b/src/ArgParser.java @@ -464,7 +464,7 @@ public class ArgParser int lvl = levels; try { outer: - while (lvl > 1) + while (lvl > 0) { InputStream is = null; try diff --git a/src/argparser.bash b/src/argparser.bash index ba9529c..c4f306b 100644 --- a/src/argparser.bash +++ b/src/argparser.bash @@ -133,7 +133,7 @@ function args_dispose function args_parent_name { local pid=$$ lvl=$1 found=0 line arg - while (( $lvl > 1 )) && [ $found = 0 ]; do + while (( $lvl > 0 )) && [ $found = 0 ]; do while read line; do if [ "${line:5}" = "PPid:" ]; then line="${line:5}" diff --git a/src/argparser.py b/src/argparser.py index a89dada..7d29ade 100644 --- a/src/argparser.py +++ b/src/argparser.py @@ -79,7 +79,7 @@ class ArgParser(): ''' pid = os.readlink('/proc/self') lvl = levels - while lvl > 1: + while lvl > 0: with file as open('/proc/%d/status' % pid, 'r'): lines = file.readlines() found = False -- cgit v1.2.3-70-g09d2