mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-08-07 09:01:38 -04:00
Use comma instead of | to avoid java split problems. Ensure that the sent string is a byte string.
This commit is contained in:
parent
15749dc4d7
commit
ff4da40412
@ -585,8 +585,9 @@ class SMART_DEVICE_APP(DeviceConfig, DevicePlugin):
|
|||||||
try:
|
try:
|
||||||
packet = self.broadcast_socket.recvfrom(100)
|
packet = self.broadcast_socket.recvfrom(100)
|
||||||
remote = packet[1]
|
remote = packet[1]
|
||||||
message = str(socket.gethostname().partition('.')[0]
|
message = str(b'calibre smart device client on ' +
|
||||||
+ '|') + str(self.port)
|
str(socket.gethostname().partition('.')[0]) +
|
||||||
|
b',' + str(self.port))
|
||||||
self._debug('received broadcast', packet, message)
|
self._debug('received broadcast', packet, message)
|
||||||
self.broadcast_socket.sendto(message, remote)
|
self.broadcast_socket.sendto(message, remote)
|
||||||
except:
|
except:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user