Change in vdsm[master]: fileUtils: remove unused method 'isStaleHandle'

ykaplan at redhat.com ykaplan at redhat.com
Tue Apr 29 09:12:19 UTC 2014


Yeela Kaplan has uploaded a new change for review.

Change subject: fileUtils: remove unused method 'isStaleHandle'
......................................................................

fileUtils: remove unused method 'isStaleHandle'

Change-Id: Ie183280861a1f268fc1faa244db3b2cc2dddbb97
Signed-off-by: Yeela Kaplan <ykaplan at redhat.com>
---
M vdsm/storage/fileUtils.py
1 file changed, 0 insertions(+), 19 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/80/27180/1

diff --git a/vdsm/storage/fileUtils.py b/vdsm/storage/fileUtils.py
index 56dc1ef..b4dbd14 100644
--- a/vdsm/storage/fileUtils.py
+++ b/vdsm/storage/fileUtils.py
@@ -68,25 +68,6 @@
         raise TarCopyFailed(tsrc.returncode, tdst.returncode, out, err)
 
 
-def isStaleHandle(path):
-    exists = os.path.exists(path)
-    st = False
-    try:
-        os.statvfs(path)
-        st = True
-        os.listdir(path)
-    except OSError as ex:
-        if ex.errno in (errno.EIO, errno.ESTALE):
-            return True
-
-        # We could get contradictory results because of
-        # soft mounts
-        if (exists or st) and ex.errno == errno.ENOENT:
-            return True
-
-    return False
-
-
 def transformPath(remotePath):
     """
     Transform remote path to new one for local mount


-- 
To view, visit http://gerrit.ovirt.org/27180
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie183280861a1f268fc1faa244db3b2cc2dddbb97
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yeela Kaplan <ykaplan at redhat.com>


More information about the vdsm-patches mailing list