summaryrefslogtreecommitdiffstats
path: root/envsetup.sh
diff options
context:
space:
mode:
Diffstat (limited to 'envsetup.sh')
-rw-r--r--envsetup.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/envsetup.sh b/envsetup.sh
index 314a539..a0dbf3d 100644
--- a/envsetup.sh
+++ b/envsetup.sh
@@ -2171,7 +2171,11 @@ function dopush()
adb remount &> /dev/null
mkdir -p $OUT
- $func $* | tee $OUT/.log
+ ($func $*|tee $OUT/.log;return ${PIPESTATUS[0]})
+ ret=$?;
+ if [ $ret -ne 0 ]; then
+ rm -f $OUT/.log;return $ret
+ fi
# Install: <file>
LOC="$(cat $OUT/.log | sed -r 's/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]//g' | grep '^Install: ' | cut -d ':' -f 2)"