summaryrefslogtreecommitdiffstats
path: root/swift/1.4.8
diff options
context:
space:
mode:
authorPeter Portante <peter.portante@redhat.com>2012-10-17 15:25:34 -0400
committerAnand Avati <avati@redhat.com>2012-10-17 15:45:56 -0700
commit2b8043986e6f35a91bf1919c657d73f67b905ef7 (patch)
tree7a2198fb94fd9cb415ea88b83f3aa8e67b86b55a /swift/1.4.8
parentdbe793bcde5d0ba936eceb19bcb8a6f376a0dbc4 (diff)
object-storage: Don't catch generic exceptions around xattr calls
We should really avoid catching generic Exception objects around any of our system calls. This simple fix brings this code in line with the other code wrapping xattr calls. Change-Id: I75492a61081fbfbec34c8d91a47214858c67e405 Signed-off-by: Peter Portante <peter.portante@redhat.com> Reviewed-on: http://review.gluster.org/4099 Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com> Tested-by: Anand Avati <avati@redhat.com>
Diffstat (limited to 'swift/1.4.8')
-rw-r--r--swift/1.4.8/plugins/utils.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/swift/1.4.8/plugins/utils.py b/swift/1.4.8/plugins/utils.py
index 59e704702cd..7a67c1cb695 100644
--- a/swift/1.4.8/plugins/utils.py
+++ b/swift/1.4.8/plugins/utils.py
@@ -274,8 +274,8 @@ def check_user_xattr(path):
raise
try:
xattr.remove(path, 'user.test.key1')
- except Exception, err:
- logging.exception("xattr.remove failed on %s err: %s", path, str(err))
+ except IOError as err:
+ logging.exception("check_user_xattr: remove failed on %s err: %s", path, str(err))
#Remove xattr may fail in case of concurrent remove.
return True