aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2017-12-05 17:34:08 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-12-10 22:41:42 +0000
commit33bf6e05af0a68da32f0484460b1de5f7f4eea98 (patch)
treec817c0bc7abbf9028aadd15b9c87ab5da9cdfd2d
parent9e7aed823d3035b8429d3c5fc537cacadf16f675 (diff)
downloadopenembedded-core-contrib-33bf6e05af0a68da32f0484460b1de5f7f4eea98.tar.gz
openembedded-core-contrib-33bf6e05af0a68da32f0484460b1de5f7f4eea98.tar.bz2
openembedded-core-contrib-33bf6e05af0a68da32f0484460b1de5f7f4eea98.zip
sanity: getstatusoutput returns an int, not a string
This code is an error path so nobody noticed that oe.utils.getstatusoutput() is just a wrapper around subprocess.getstatusoutput() which returns an (int, string) pair not (string, string). Signed-off-by: Ross Burton <ross.burton@intel.com>
-rw-r--r--meta/classes/sanity.bbclass6
1 files changed, 3 insertions, 3 deletions
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index 1feb7949daa..1410af29017 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -462,7 +462,7 @@ def check_make_version(sanity_data):
from distutils.version import LooseVersion
status, result = oe.utils.getstatusoutput("make --version")
if status != 0:
- return "Unable to execute make --version, exit code %s\n" % status
+ return "Unable to execute make --version, exit code %d\n" % status
version = result.split()[2]
if LooseVersion(version) == LooseVersion("3.82"):
# Construct a test file
@@ -498,7 +498,7 @@ def check_tar_version(sanity_data):
from distutils.version import LooseVersion
status, result = oe.utils.getstatusoutput("tar --version")
if status != 0:
- return "Unable to execute tar --version, exit code %s\n" % status
+ return "Unable to execute tar --version, exit code %d\n" % status
version = result.split()[3]
if LooseVersion(version) < LooseVersion("1.24"):
return "Your version of tar is older than 1.24 and has bugs which will break builds. Please install a newer version of tar.\n"
@@ -511,7 +511,7 @@ def check_git_version(sanity_data):
from distutils.version import LooseVersion
status, result = oe.utils.getstatusoutput("git --version 2> /dev/null")
if status != 0:
- return "Unable to execute git --version, exit code %s\n" % status
+ return "Unable to execute git --version, exit code %d\n" % status
version = result.split()[2]
if LooseVersion(version) < LooseVersion("1.8.3.1"):
return "Your version of git is older than 1.8.3.1 and has bugs which will break builds. Please install a newer version of git.\n"