From a98be6fc2e7dfbf2dfff90bcecb672beb2a0a71e Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 15 Sep 2013 02:36:12 -0700 Subject: [PATCH] _copyxattr: ignore EOPNOTSUPP from os.listxattr() This will fix bug #484540. --- pym/portage/util/movefile.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pym/portage/util/movefile.py b/pym/portage/util/movefile.py index 8ce80f1aa..e9b01be22 100644 --- a/pym/portage/util/movefile.py +++ b/pym/portage/util/movefile.py @@ -72,7 +72,12 @@ if hasattr(_os, "getxattr"): # Python >=3.3 and GNU/Linux def _copyxattr(src, dest, exclude=None): - attrs = _os.listxattr(src) + try: + attrs = _os.listxattr(src) + except OSError as e: + if e.errno != OperationNotSupported.errno: + raise + attrs = () if attrs: if exclude is not None and isinstance(attrs[0], bytes): exclude = exclude.encode(_encodings['fs']) -- 2.26.2