From f83a50a7bfc43216e75d4fbf0155b06b47520d62 Mon Sep 17 00:00:00 2001 From: Dirk Thomas Date: Fri, 8 Nov 2013 10:28:00 -0800 Subject: [PATCH] allow different 127. addresses than 127.0.0.1 (fix #315) --- tools/rosgraph/src/rosgraph/network.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/rosgraph/src/rosgraph/network.py b/tools/rosgraph/src/rosgraph/network.py index ee3ac6a88e..af69d2fc78 100644 --- a/tools/rosgraph/src/rosgraph/network.py +++ b/tools/rosgraph/src/rosgraph/network.py @@ -254,6 +254,8 @@ def get_bind_address(address=None): #localhost or 127/8 if use_ipv6(): return '::1' + elif address.startswith('127.'): + return address else: return '127.0.0.1' #loopback else: