diff options
author | Roger Dingledine <arma@torproject.org> | 2003-10-17 04:48:20 +0000 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2003-10-17 04:48:20 +0000 |
commit | 5c563939ef7048749b775d3e2bf5dc26b39161d2 (patch) | |
tree | ea3045142a36efcf777575d7acf8055d0f8afe5c /src/or/routers.c | |
parent | 25b0c92f0fd34905bf9c51c7d658b88865fd3000 (diff) | |
download | tor-5c563939ef7048749b775d3e2bf5dc26b39161d2.tar tor-5c563939ef7048749b775d3e2bf5dc26b39161d2.tar.gz |
catch misconfigured machines that return hostname as fqdn
svn:r610
Diffstat (limited to 'src/or/routers.c')
-rw-r--r-- | src/or/routers.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/or/routers.c b/src/or/routers.c index 292e045b7..121d66bb3 100644 --- a/src/or/routers.c +++ b/src/or/routers.c @@ -1130,6 +1130,10 @@ int router_rebuild_descriptor(void) { return -1; } address = localhostname; + if(!strchr(address,'.')) { + log_fn(LOG_WARN,"fqdn '%s' has only one element. Misconfigured machine?",address); + return -1; + } } ri = tor_malloc(sizeof(routerinfo_t)); ri->address = tor_strdup(address); |