Skip to content

Commit

Permalink
Fix print
Browse files Browse the repository at this point in the history
  • Loading branch information
relativityspace-jsmith committed Mar 26, 2024
1 parent cb59465 commit 021af2e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/mcast_communicator.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def listener_thread(machine_index: int, addr_family: int, iface_ip: str) -> None
if len(sys.argv) > 3:
iface_ip = sys.argv[3]
else:
iface_ip = multicast_expert.get_default_gateway_iface_ip_v4()
iface_ip = multicast_expert.get_default_gateway_iface_ip(addr_family)
if iface_ip is None:
print("Unable to determine default gateway. Please specify interface in arguments.")
exit(1)
Expand All @@ -88,7 +88,7 @@ def listener_thread(machine_index: int, addr_family: int, iface_ip: str) -> None
listener_thread_obj.start()

# Start transmitting
print("Communicator starting on interface %s. Press Ctrl-C to exit" % (multicast_expert.get_default_gateway_iface_ip(addr_family)))
print("Communicator starting on interface %s. Press Ctrl-C to exit" % (iface_ip,))
with multicast_expert.McastTxSocket(addr_family=addr_family, mcast_ips=[MULTICAST_ADDRESSES[addr_family][0], MULTICAST_ADDRESSES[addr_family][machine_number]], iface_ip=iface_ip) as tx_socket:
while True:
time.sleep(1.0)
Expand Down

0 comments on commit 021af2e

Please sign in to comment.