|
Lines 89-95
def _timeout_connection(self, state):
Link Here
|
| 89 |
"""Closes the connection after a specified timeout""" |
89 |
"""Closes the connection after a specified timeout""" |
| 90 |
state.time_remaining -= 1 |
90 |
state.time_remaining -= 1 |
| 91 |
|
91 |
|
| 92 |
if state.time_remaining <= 0 and not state.requests: |
92 |
if state.time_remaining <= 0 and not state.requests and not state.session.has_active_module_processes(): |
| 93 |
CORE.process('Connection timed out.') |
93 |
CORE.process('Connection timed out.') |
| 94 |
self._cleanup(state.socket) |
94 |
self._cleanup(state.socket) |
| 95 |
else: |
95 |
else: |
|
Lines 192-197
def _response(self, msg, state):
Link Here
|
| 192 |
CORE.info('The given response is invalid or not known (%s)' % (msg.id,)) |
192 |
CORE.info('The given response is invalid or not known (%s)' % (msg.id,)) |
| 193 |
return |
193 |
return |
| 194 |
|
194 |
|
|
|
195 |
state.reset_connection_timeout() |
| 195 |
try: |
196 |
try: |
| 196 |
data = str(msg) |
197 |
data = str(msg) |
| 197 |
# there is no data from another request in the send queue |
198 |
# there is no data from another request in the send queue |