mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-22 10:30:13 +00:00
moved release lock to before return response
This commit is contained in:
parent
217056b8bd
commit
474edac0f5
@ -282,11 +282,12 @@ class Shepherd:
|
||||
debug(Debug, response.toprettyxml())
|
||||
if response.documentElement.tagName == 'error':
|
||||
raise chakana.error.CoojaError(response)
|
||||
self._connectionLock.release()
|
||||
return response
|
||||
except socket.error:
|
||||
debug(MajorEvent, 'Socket error catched')
|
||||
finally:
|
||||
self._connectionLock.release()
|
||||
except AttributeError:
|
||||
debug(MajorEvent, 'Attribute error catched')
|
||||
|
||||
def readFromCooja(self):
|
||||
# XXX: Assume message ends with a newline
|
||||
|
Loading…
Reference in New Issue
Block a user