Fixes catching AttributeErrors it shouldn't.
Signed-off-by: Dylan Baker <[email protected]>
---
piglit | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/piglit b/piglit
index 4ce6c41..6c1d30a 100755
--- a/piglit
+++ b/piglit
@@ -163,11 +163,11 @@ def main():
# to that executable
parsed, args = parser.parse_known_args(input_)
try:
- returncode = parsed.func(args)
+ runner = parsed.func
except AttributeError:
parser.print_help()
sys.exit(1)
- sys.exit(returncode)
+ sys.exit(runner(args))
if __name__ == '__main__':
--
git-series 0.8.10
_______________________________________________
Piglit mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/piglit