Browse Source

don't crash in case a frame cannot be sent

master
Fr3deric 7 years ago
parent
commit
2f8df5467d
  1. 4
      utils/blphub.py

4
utils/blphub.py

@ -69,7 +69,11 @@ class BLPHub(): @@ -69,7 +69,11 @@ class BLPHub():
self.__lastFrameTimeout = (
currentTime + self.__streams[stream]['timeout']
)
try:
self.__output.sendFrame(frame)
except Exception as e:
# TODO better error handling
print('could not send frame: %s' % (repr(e)))
return True
return False

Loading…
Cancel
Save