]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
coverity.sh: make the script compatible with Python 3
authorEvegeny Vereshchagin <evvers@ya.ru>
Mon, 25 Jun 2018 21:59:28 +0000 (21:59 +0000)
committerEvegeny Vereshchagin <evvers@ya.ru>
Mon, 25 Jun 2018 21:59:28 +0000 (21:59 +0000)
tools/coverity.sh

index 0e04555a489679f37046e0d628600029b1b95b24..40acbb0411bd9df67a677dde3d52998aade054e7 100755 (executable)
@@ -42,11 +42,11 @@ if [ "$AUTH_RES" = "Access denied" ]; then
   echo -e "\033[33;1mCoverity Scan API access denied. Check COVERITY_SCAN_PROJECT_NAME and COVERITY_SCAN_TOKEN.\033[0m"
   exit 1
 else
-  AUTH=`echo $AUTH_RES | python -c "import sys, json; print json.load(sys.stdin)['upload_permitted']"`
+  AUTH=`echo $AUTH_RES | python -c "import sys, json; print(json.load(sys.stdin)['upload_permitted'])"`
   if [ "$AUTH" = "True" ]; then
     echo -e "\033[33;1mCoverity Scan analysis authorized per quota.\033[0m"
   else
-    WHEN=`echo $AUTH_RES | python -c "import sys; json; print json.load(sys.stdin)['next_upload_permitted_at']"`
+    WHEN=`echo $AUTH_RES | python -c "import sys; json; print(json.load(sys.stdin)['next_upload_permitted_at'])"`
     echo -e "\033[33;1mCoverity Scan analysis NOT authorized until $WHEN.\033[0m"
     exit 0
   fi