Skip to content

Commit

Permalink
Fix send message deadlock (#180)
Browse files Browse the repository at this point in the history
* Fix deadlock in SocketClient.send_message

* Fix for #179
  • Loading branch information
emontnemery authored and emlove committed Jul 13, 2017
1 parent 819ccb6 commit 75beb09
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pychromecast/socket_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -590,7 +590,7 @@ def send_message(self, destination_id, namespace, data,
}
self.socket.sendall(be_size + msg.SerializeToString())
except socket.error:
del self._request_callbacks[request_id]
self._request_callbacks.pop(request_id, None)
self._force_recon = True
self.logger.info('Error writing to socket.')
else:
Expand Down

0 comments on commit 75beb09

Please sign in to comment.