Skip to content

Commit

Permalink
fix regression of PR ros#515
Browse files Browse the repository at this point in the history
  • Loading branch information
dirk-thomas committed Dec 10, 2014
1 parent 6868cbf commit bb13439
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/rosgraph/src/rosgraph/network.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,9 +168,9 @@ def is_local_address(hostname):
"""
try:
if use_ipv6():
reverse_ips = [host[4][0] for host in socket.getaddrinfo(socket.gethostname(), 0, 0, 0, socket.SOL_TCP)]
reverse_ips = [host[4][0] for host in socket.getaddrinfo(hostname, 0, 0, 0, socket.SOL_TCP)]
else:
reverse_ips = [host[4][0] for host in socket.getaddrinfo(socket.gethostname(), 0, socket.AF_INET, 0, socket.SOL_TCP)]
reverse_ips = [host[4][0] for host in socket.getaddrinfo(hostname, 0, socket.AF_INET, 0, socket.SOL_TCP)]
except socket.error:
return False
local_addresses = ['localhost'] + get_local_addresses()
Expand Down

0 comments on commit bb13439

Please sign in to comment.