correct error handling for retrieving file size

git-svn-id: svn://svn.cy55.de/Zope3/src/cybertools/trunk@3468 fd906abe-77d9-0310-91a1-e0d9ade77398
This commit is contained in:
helmutm 2009-07-22 07:28:44 +00:00
parent 380c57ceba
commit d4b4360450

View file

@ -84,7 +84,7 @@ class FileSystemStorage(object):
fn = self.getDir(address, subDir)
try:
return os.path.getsize(fn)
except IOError, e:
except OSError, e:
from logging import getLogger
getLogger('cybertools.storage.filesystem.FileSystemStorage').warn(e)
return 0