Skip to content

Commit 1151eba

Browse files
committed
encodedsession: Check for timeout and throw if detected
Without this we will try to access a None object.
1 parent f93ab4f commit 1151eba

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

pynuodb/encodedsession.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1085,6 +1085,9 @@ def _exchangeMessages(self, getResponse=True):
10851085
self.__input = self.recv(False)
10861086
self.__inpos = 0
10871087

1088+
if self.__input is None:
1089+
db_error_handler(protocol.OPERATION_TIMEOUT, "timed out")
1090+
10881091
error = self.getInt()
10891092

10901093
if error != 0:

0 commit comments

Comments
 (0)