[PATCH 05/10] oeqa/utils/commands: fix usage of undefined EPIPE

Enrico Jorns
2023-03-31T10:26:47Z

meta/lib/oeqa/utils/commands.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py
index f4daea2507..84c463328f 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
--
2.39.2