[oe-commits] [openembedded-core] 15/21: class/sanity: strip the output of get_filesystem_id()
git at git.openembedded.org
git at git.openembedded.org
Mon Mar 18 11:13:09 UTC 2019
This is an automated email from the git hooks/post-receive script.
rpurdie pushed a commit to branch master
in repository openembedded-core.
commit 172c3e85c601a61f3c668f83b75f4c1eb31dbd4d
Author: Steven Hung (洪于玉) <Steven.Hung at mediatek.com>
AuthorDate: Wed Mar 13 06:26:05 2019 +0000
class/sanity: strip the output of get_filesystem_id()
A previous commit 2f44b9b replace oe.utils.getstatusoutput() to
subprocess.check_output(). check_output() don't remove a trailling newline. Add strip()
Signed-off-by: Steven Hung (洪于玉) <Steven.Hung at mediatek.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
meta/classes/sanity.bbclass | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index 374dacf..cab0921 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -338,7 +338,7 @@ def check_path_length(filepath, pathname, limit):
def get_filesystem_id(path):
import subprocess
try:
- return subprocess.check_output(["stat", "-f", "-c", "%t", path]).decode('utf-8')
+ return subprocess.check_output(["stat", "-f", "-c", "%t", path]).decode('utf-8').strip()
except subprocess.CalledProcessError:
bb.warn("Can't get filesystem id of: %s" % path)
return None
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Openembedded-commits
mailing list