Skip to contentSkip to conversation

docker: Inline "prep_fail" in run script

PATCH Applied Fam Zheng 2 participants 3 messages Mar 26, 2018 – Apr 4, 2018

lore
Share & tools
lore

Fam Zheng

author
#0 lore raw

PATCH 1/1 docker: Inline "prep_fail" in run script

We don't source common.rc where prep_fail is defined, so spell out the commands and do what was intended.

---
 tests/docker/run | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/docker/run +1 -1
index 9dd362bb98..7aebf4b569 100755
@@ -29,7 +29,7 @@ export TEST_DIR=/tmp/qemu-test
 mkdir -p $TEST_DIR/{src,build,install}
 
 # Extract the source tarballs
-tar -C $TEST_DIR/src -xf $BASE/qemu.tar || prep_fail "Failed to untar source"
+tar -C $TEST_DIR/src -xf $BASE/qemu.tar || { echo "Failed to untar source"; exit 2; }
 if test -f $TEST_DIR/src/Makefile; then
     export FEATURES="$FEATURES dtc"
 fi
Signature · 1 line
2.14.3
Reviewed-by on v1 1/1
#1 lore raw
Quoted 13 lines · Fam Zheng

We don't source common.rc where prep_fail is defined, so spell out the commands and do what was intended.

---
 tests/docker/run | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/docker/run +0 -0
index 9dd362bb98..7aebf4b569 100755

tests/docker/run export TEST_DIR=/tmp/qemu-test · line 35

Quoted 8 lines
tests/docker/run +1 -1
@@ -29,7 +29,7 @@ export TEST_DIR=/tmp/qemu-test
 mkdir -p $TEST_DIR/{src,build,install}
 
 # Extract the source tarballs
-tar -C $TEST_DIR/src -xf $BASE/qemu.tar || prep_fail "Failed to untar source"
+tar -C $TEST_DIR/src -xf $BASE/qemu.tar || { echo "Failed to untar source"; exit 2; }
 if test -f $TEST_DIR/src/Makefile; then
     export FEATURES="$FEATURES dtc"
 fi
author Applied
#2 lore raw
In reply to Fam Zheng
Quoted 24 lines · Fam Zheng

We don't source common.rc where prep_fail is defined, so spell out the commands and do what was intended.

---
 tests/docker/run | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/docker/run +1 -1
index 9dd362bb98..7aebf4b569 100755
@@ -29,7 +29,7 @@ export TEST_DIR=/tmp/qemu-test
 mkdir -p $TEST_DIR/{src,build,install}
 
 # Extract the source tarballs
-tar -C $TEST_DIR/src -xf $BASE/qemu.tar || prep_fail "Failed to untar source"
+tar -C $TEST_DIR/src -xf $BASE/qemu.tar || { echo "Failed to untar source"; exit 2; }
 if test -f $TEST_DIR/src/Makefile; then
     export FEATURES="$FEATURES dtc"
 fi
Signature · 1 line
2.14.3

Queued, thanks!

Fam