Commit 737b2b43 authored by Jeremy Hylton's avatar Jeremy Hylton

Be prepared for a call that returns an empty tuple.

parent bbdb0e31
...@@ -341,7 +341,7 @@ class Connection(smac.SizedMessageAsyncConnection): ...@@ -341,7 +341,7 @@ class Connection(smac.SizedMessageAsyncConnection):
raise DisconnectedError() raise DisconnectedError()
msgid = self.send_call(method, args, 0) msgid = self.send_call(method, args, 0)
r_flags, r_args = self.wait(msgid) r_flags, r_args = self.wait(msgid)
if (isinstance(r_args, types.TupleType) if (isinstance(r_args, types.TupleType) and len(r_args) > 1
and type(r_args[0]) == types.ClassType and type(r_args[0]) == types.ClassType
and issubclass(r_args[0], Exception)): and issubclass(r_args[0], Exception)):
inst = r_args[1] inst = r_args[1]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment