diff --git a/tests/hwsim/run-all.sh b/tests/hwsim/run-all.sh index ee48cd058..7c50edd79 100755 --- a/tests/hwsim/run-all.sh +++ b/tests/hwsim/run-all.sh @@ -15,7 +15,11 @@ export LOGDIR if [ -z "$DBFILE" ]; then DB="" else - DB="-S $DBFILE --commit $(git rev-parse HEAD)" + DB="-S $DBFILE" + COMMITID="$(git rev-parse HEAD)" + if [ -n "$COMMITID" ]; then + DB="$DB --commit $COMMITID" + fi if [ -n "$BUILD" ]; then DB="$DB -b $BUILD" fi