From c1d0737aba3c0059114b071343eeb71c4781ea0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A1zaro=20Clapp?= Date: Thu, 18 Jun 2020 16:15:30 -0400 Subject: [PATCH] Fix: android-jar.py's exit code. (#399) This script would not propagate the exit code from the final call to jarinfer, leading it to potentially return success even when jarinfer fails to run. This is not critical, since this script is only used for the release process and other steps will fail before publishing to maven central. Still worth fixing, though. Credit to Clint Gibler, R2C, and the semgrep tool for finding this. --- jar-infer/scripts/android-jar.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/jar-infer/scripts/android-jar.py b/jar-infer/scripts/android-jar.py index 5cd675cfd8..be3fa707e7 100644 --- a/jar-infer/scripts/android-jar.py +++ b/jar-infer/scripts/android-jar.py @@ -50,4 +50,5 @@ if options.verbose: cmd += " -dv" print cmd -subprocess.call(cmd, shell=True) +returncode = subprocess.call(cmd, shell=True) +sys.exit(returncode)