diff options
author | 2012-04-18 10:56:09 +0100 | |
---|---|---|
committer | 2012-04-18 11:57:30 +0100 | |
commit | f4eed2b8b87f8b705c3f3a55665a2069dced31cf (patch) | |
tree | d2673e24ac6f920cb5e3b420fa2268eaef55bb60 | |
parent | d73e41f4375f8f6056f01f1475aca20545c02ad4 (diff) | |
download | poky-f4eed2b8b87f8b705c3f3a55665a2069dced31cf.tar.gz poky-f4eed2b8b87f8b705c3f3a55665a2069dced31cf.tar.bz2 poky-f4eed2b8b87f8b705c3f3a55665a2069dced31cf.zip |
classes/sanity: trim trailing newline when reading /etc/redhat-release
Any trailing whitespace needs to be stripped before comparing it to the
SANITY_TESTED_DISTROS list.
(From OE-Core rev: bea0311a6478febe8ab4884fb1c479f610856534)
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes/sanity.bbclass | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass index 4d4abd3ea5..3ec449c746 100644 --- a/meta/classes/sanity.bbclass +++ b/meta/classes/sanity.bbclass @@ -120,7 +120,7 @@ def check_supported_distro(e): if os.path.exists("/etc/redhat-release"): f = open("/etc/redhat-release", "r") try: - distro = f.readline() + distro = f.readline().strip() finally: f.close() elif os.path.exists("/etc/SuSE-release"): |