Change in vdsm[master]: ksm: janitorial: with construct, file() to open()

fromani at redhat.com fromani at redhat.com
Wed Dec 18 12:32:35 UTC 2013


Francesco Romani has posted comments on this change.

Change subject: ksm: janitorial: with construct, file() to open()
......................................................................


Patch Set 5:

(1 comment)

....................................................
File vdsm/ksm.py
Line 34: 
Line 35: def _readProcFSInt(path):
Line 36:     try:
Line 37:         return int(_readFile(path))
Line 38:     except (IOError, ValueError):
I'm actually trying to narrow down the exception catched. Previously, this code was wrapped a in try/except: block (e.g. npages()).
I picked the exceptions which IMO make sense to handle in this context and for this purpose.
Line 39:         return 0
Line 40: 
Line 41: 
Line 42: class KsmMonitorThread(threading.Thread):


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I47213b3d85eac9afd4cb316c50b192b9c1dfbbd8
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Antoni Segura Puimedon <asegurap at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list