]> code.citadel.org Git - citadel.git/blobdiff - webcit/serv_func.c
* Simplified tcp_connectsock()
[citadel.git] / webcit / serv_func.c
index 1069858e5cba8790404ea69bfd02a5167547f24c..50bf1f771d993d5f306d67fd9ece24090d53562e 100644 (file)
@@ -168,7 +168,7 @@ int GetConnected (void)
        if (is_uds) /* unix domain socket */
                WCC->serv_sock = uds_connectsock(serv_sock_name);
        else        /* tcp socket */
-               WCC->serv_sock = tcp_connectsock(ctdlhost, ctdlport);
+               WCC->serv_sock = tcp_connectsock(ctdlhost, atoi(ctdlport));
        
        if (WCC->serv_sock < 0) {
                do_logout();
@@ -182,7 +182,6 @@ int GetConnected (void)
                WCC->connected = 1;
                StrBuf_ServGetln(Buf);  /* get the server greeting */
                short_status = GetServerStatus(Buf, &Status);
-               lprintf(9, "\033[32mGREETING: %s\033[0m\n", ChrPtr(Buf));
                FreeStrBuf(&Buf);
 
                /* Server isn't ready for us? */
@@ -201,6 +200,8 @@ int GetConnected (void)
                        return 1;
                }
 
+               /* 2010jun03: every now and then the connection to Citadel dies before this point.  why? */
+
                /*
                 * From what host is our user connecting?  Go with
                 * the host at the other end of the HTTP socket,