From: Enrico Jörns Date: Fri, 31 Mar 2023 10:26:17 +0000 (+0200) Subject: oeqa/utils/commands: fix usage of undefined EPIPE X-Git-Tag: yocto-4.1.4~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d0eeb32cb0d990698287955dd7cac643bcebdafc;p=thirdparty%2Fopenembedded%2Fopenembedded-core.git oeqa/utils/commands: fix usage of undefined EPIPE Signed-off-by: Enrico Jorns Signed-off-by: Richard Purdie (cherry picked from commit 1cb17e37e275794e26debed2d171c2394d8bb945) Signed-off-by: Steve Sakoman --- diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py index f733fcdf3c8..c03ba52ef2e 100644 --- a/meta/lib/oeqa/utils/commands.py +++ b/meta/lib/oeqa/utils/commands.py @@ -21,6 +21,7 @@ from oeqa.utils import CommandError from oeqa.utils import ftools import re import contextlib +import errno # Export test doesn't require bb try: import bb @@ -85,7 +86,7 @@ class Command(object): except OSError as ex: # It's not an error when the command does not consume all # of our data. subprocess.communicate() also ignores that. - if ex.errno != EPIPE: + if ex.errno != errno.EPIPE: raise # We write in a separate thread because then we can read