]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
commit some minor fixes from this sandbox so i can commit the next one
authorRoger Dingledine <arma@torproject.org>
Sun, 15 Aug 2004 05:28:09 +0000 (05:28 +0000)
committerRoger Dingledine <arma@torproject.org>
Sun, 15 Aug 2004 05:28:09 +0000 (05:28 +0000)
svn:r2229

src/or/config.c
src/or/connection.c
src/or/connection_or.c

index d9f9856ecfbfb544164fbdd67908a00b1c673b94..4706f7c5aed74adf499011af4f0f45b88288c4c1 100644 (file)
@@ -431,13 +431,6 @@ static int resolve_my_address(or_options_t *options) {
       log_fn(LOG_WARN,"Error obtaining local hostname");
       return -1;
     }
-#if 0 /* don't worry about complaining, as long as it resolves */
-    if(!strchr(localhostname,'.')) {
-      log_fn(LOG_WARN,"fqdn '%s' has only one element. Misconfigured machine?",address);
-      log_fn(LOG_WARN,"Try setting the Address line in your config file.");
-      return -1;
-    }
-#endif
     options->Address = tor_strdup(localhostname);
     log_fn(LOG_DEBUG,"Guessed local host name as '%s'",options->Address);
   }
index 3ea4fd6bab9f4a92a32f7984da2bf9b84f7962f0..f37cae100ae906726feaccd5c034e2aa2b6f1358 100644 (file)
@@ -478,7 +478,8 @@ int connection_connect(connection_t *conn, char *address, uint32_t addr, uint16_
 
   s=socket(PF_INET,SOCK_STREAM,IPPROTO_TCP);
   if (s < 0) {
-    log_fn(LOG_WARN,"Error creating network socket.");
+    log_fn(LOG_WARN,"Error creating network socket: %s",
+           tor_socket_strerror(tor_socket_errno(-1)));
     return -1;
   }
   set_socket_nonblocking(s);
index 43cdb682f583b8cd57bd4c1d4c0407fdb7d82b47..2d18e90e268ab632fe8452a3dc6794492b95f9dd 100644 (file)
@@ -167,6 +167,7 @@ connection_t *connection_or_connect(uint32_t addr, uint16_t port,
 
   /* this function should never be called if we're already connected to
    * id_digest, but check first to be sure */
+/*XXX008 this is getting called, at least by dirservers. */
   conn = connection_get_by_identity_digest(id_digest, CONN_TYPE_OR);
   if(conn) {
     tor_assert(conn->nickname);