]> code.ossystems Code Review - openembedded-core.git/commit
package: Clean up getstatusoutput usage
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 20 Jul 2018 15:44:05 +0000 (15:44 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 24 Jul 2018 10:52:07 +0000 (11:52 +0100)
commit9f058857fb692f1251deb43bcaa7ed0120140093
treec24e3e11733de11f67d7ee2fe58fed69127eda63
parent2de56aa0792ec93445130d801936a8ea643fad27
package: Clean up getstatusoutput usage

Replace usage of oe.utils.getstatusoutput() with direct subprocess calls. The
call is just a wraper to the subprocess call of the same name and requires
the caller to handle exceptions themselves. We usually do this badly, failing
to show the output or the command or the return code.

Its much safer to rely on a call like subprocess.check_output() instead.

This also makes it easier to spot and remove cases where shell=True isn't
needed in a later cleanup.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/package.bbclass