From 972c252c41e516e7ce54406ac79b0a35adb88bca Mon Sep 17 00:00:00 2001 From: Thiago da Silva Date: Tue, 25 Mar 2014 14:53:12 -0400 Subject: removing check_user_xattr function This function is no longer used, the code that called this function was removed as part of this patch: http://review.gluster.com/#/c/3390/ Change-Id: I6e81e4b763ce302289e2be5467dc4776f0750c15 Signed-off-by: Thiago da Silva Reviewed-on: http://review.gluster.org/7336 Reviewed-by: Luis Pabon Tested-by: Luis Pabon --- gluster/swift/common/utils.py | 18 ------------------ 1 file changed, 18 deletions(-) (limited to 'gluster') diff --git a/gluster/swift/common/utils.py b/gluster/swift/common/utils.py index 0b2ad28..f2e112a 100644 --- a/gluster/swift/common/utils.py +++ b/gluster/swift/common/utils.py @@ -168,24 +168,6 @@ def clean_metadata(path_or_fd): key += 1 -def check_user_xattr(path): - if not os_path.exists(path): - return False - try: - xattr.setxattr(path, 'user.test.key1', 'value1') - except IOError as err: - raise GlusterFileSystemIOError( - err.errno, - 'xattr.setxattr("%s", "user.test.key1", "value1")' % (path,)) - try: - xattr.removexattr(path, 'user.test.key1') - 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 - - def validate_container(metadata): if not metadata: logging.warn('validate_container: No metadata') -- cgit