[Zodb-checkins] CVS: ZODB3/ZEO/zrpc - trigger.py:1.8.2.1
Guido van Rossum
guido@python.org
Tue, 12 Nov 2002 08:35:59 -0500
Update of /cvs-repository/ZODB3/ZEO/zrpc
In directory cvs.zope.org:/tmp/cvs-serv25532
Modified Files:
Tag: ZODB3-3_1-branch
trigger.py
Log Message:
Perhaps belt and suspenders: in handle_read() (both versions!), catch
socket errors from the recv() call and return early in that case.
=== ZODB3/ZEO/zrpc/trigger.py 1.8 => 1.8.2.1 ===
--- ZODB3/ZEO/zrpc/trigger.py:1.8 Wed Oct 2 14:37:17 2002
+++ ZODB3/ZEO/zrpc/trigger.py Tue Nov 12 08:35:58 2002
@@ -95,7 +95,10 @@
os.write(self.trigger, 'x')
def handle_read(self):
- self.recv(8192)
+ try:
+ self.recv(8192)
+ except socket.error:
+ return
self.lock.acquire()
try:
for thunk in self.thunks:
@@ -183,7 +186,10 @@
self.trigger.send('x')
def handle_read(self):
- self.recv(8192)
+ try:
+ self.recv(8192)
+ except socket.error:
+ return
self.lock.acquire()
try:
for thunk in self.thunks: