updates.
authorPekka Riikonen <priikone@silcnet.org>
Tue, 22 Jan 2002 19:35:42 +0000 (19:35 +0000)
committerPekka Riikonen <priikone@silcnet.org>
Tue, 22 Jan 2002 19:35:42 +0000 (19:35 +0000)
lib/silcclient/client.c
lib/silcutil/unix/silcunixsockconn.c

index b1099389aad451abc0a181d53476476256349c72..fd0e87bc759478fc464381dc7e555d0fdc60b252 100644 (file)
@@ -374,8 +374,10 @@ static void silc_client_start_key_exchange_cb(SilcSocketConnection sock,
 
   SILC_LOG_DEBUG(("Start"));
 
-  if (!conn->sock->hostname)
-    conn->sock->hostname = strdup(conn->remote_host);
+  /* XXX We should most likely use the resolved host name instead of the
+     one user provided for us. */
+  silc_free(conn->sock->hostname);
+  conn->sock->hostname = strdup(conn->remote_host);
   if (!conn->sock->ip)
     conn->sock->ip = strdup(conn->remote_host);
   conn->sock->port = conn->remote_port;
index a4c6c684cc0fca31d79d1948ef29e77dadffe846..f6d8744a62d1757b5d4251d8f9d7559a79b94cd4 100644 (file)
@@ -122,4 +122,5 @@ bool silc_socket_get_error(SilcSocketConnection sock, char *error,
 
   memset(error, 0, error_len);
   memcpy(error, err, strlen(err));
+  return TRUE;
 }