From: Rob Browning Date: Sat, 5 Oct 2013 18:01:37 +0000 (-0500) Subject: Handle EOPNOTSUPP as an indicator that Linux attrs are not supported. X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=4be97d75e109a339568aecd349302f1cce9faa23;p=packages%2Fb%2Fbup.git Handle EOPNOTSUPP as an indicator that Linux attrs are not supported. Add EOPNOTSUPP to the set of errno values in _add_linux_attr() that indicate Linux attrs are not supported by the target filesystem. The problem was observed on ZFS-on-Linux, 0.6.2. Thanks to Will Rouesnel for the report and an initial patch. Signed-off-by: Rob Browning --- diff --git a/lib/bup/metadata.py b/lib/bup/metadata.py index c851525..d1806b5 100644 --- a/lib/bup/metadata.py +++ b/lib/bup/metadata.py @@ -550,9 +550,7 @@ class Metadata: except OSError, e: if e.errno == errno.EACCES: add_error('read Linux attr: %s' % e) - elif e.errno == errno.ENOTTY or e.errno == errno.ENOSYS: - # ENOTTY: Function not implemented. - # ENOSYS: Inappropriate ioctl for device. + elif e.errno in (errno.ENOTTY, errno.ENOSYS, errno.EOPNOTSUPP): # Assume filesystem doesn't support attrs. return else: