Skip to content
Snippets Groups Projects
Commit 983a1cf2 authored by Katharina's avatar Katharina
Browse files

changes broadcast

parent 01442e2f
No related branches found
No related tags found
No related merge requests found
......@@ -59,8 +59,8 @@ def listen(queue, shared_data):
response = f"LEADER: {shared_data['current_leader']}".encode()
time.sleep(4) #wait before sending response that client can prepare for answer
server_socket.sendto(response, client_address) #does not work atm bc same socket for client...?
#broadcast(response) #bad solution
#server_socket.sendto(response, client_address) #does not work atm bc same socket for client...?
broadcast(response) #bad solution
#print("response:", response) #debug
print(f"Sent leader information to {client_address}: {response.decode()}") #for debug
#time.sleep(2)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment