Change in vdsm[master]: fix error handling for misc.NoIntrPoll
lvroyce at linux.vnet.ibm.com
lvroyce at linux.vnet.ibm.com
Fri Nov 30 04:07:13 UTC 2012
Royce Lv has posted comments on this change.
Change subject: fix error handling for misc.NoIntrPoll
......................................................................
Patch Set 2: (3 inline comments)
....................................................
File tests/miscTests.py
Line 1121: self.assertRaises(AssertionError, self._assertFindCaller, _foo)
Line 1122:
Line 1123:
Line 1124: class NoIntrPollTests(TestCaseBase):
Line 1125: def testNoIntr(self):
Done
Line 1126: def fakeSigchld():
Line 1127: sleepTime = 0.1
Line 1128: for i in range(3):
Line 1129: time.sleep(sleepTime)
Line 1132: intrThread = threading.Thread(target=fakeSigchld)
Line 1133: intrThread.setDaemon(True)
Line 1134: intrThread.start()
Line 1135:
Line 1136: pollIntervalMsec = 1000
Done
Line 1137: tempFd, tempPath = tempfile.mkstemp()
Line 1138:
Line 1139: poller = select.poll()
Line 1140: poller.register(tempFd, select.POLLERR)
....................................................
File vdsm/storage/misc.py
Line 1345:
Line 1346: while True:
Line 1347: try:
Line 1348: return pollfun(timeout)
Line 1349: except (OSError, select.error), e:
I checked with pipe closed and pipe write overflow raise EAGAIN, neither raised error in the poll end. Do I ignore any usecase?
Line 1350: if e.args[0] != errno.EINTR:
Line 1351: raise
Line 1352: timeout = max(0, endtime - time.time())
Line 1353:
--
To view, visit http://gerrit.ovirt.org/9458
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I272654a9006fdab77e5fab608ac287416d75843e
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Royce Lv <lvroyce at linux.vnet.ibm.com>
Gerrit-Reviewer: Barak Azulay <bazulay at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Royce Lv <lvroyce at linux.vnet.ibm.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
More information about the vdsm-patches
mailing list