* Made one more byte available in locate_host() and in all the structs which
authorArt Cancro <ajc@citadel.org>
Sun, 8 Aug 1999 00:25:45 +0000 (00:25 +0000)
committerArt Cancro <ajc@citadel.org>
Sun, 8 Aug 1999 00:25:45 +0000 (00:25 +0000)
  its output gets written to (client can display 24 positions but we were only
  saving 23).

citadel/ChangeLog
citadel/locate_host.c
citadel/serv_icq.c
citadel/server.h

index 8c38d731710f0d30122c908bdcaeed1fc422f0c1..e0220a49195d39c450f43f2064952e676e86ac12 100644 (file)
@@ -1,6 +1,11 @@
 $Log$
+Revision 1.349  1999/08/08 00:25:45  ajc
+* Made one more byte available in locate_host() and in all the structs which
+  its output gets written to (client can display 24 positions but we were only
+  saving 23).
+
 Revision 1.348  1999/08/07 16:34:38  nbryant
-       * serv_icq.c: warning fixes
+* serv_icq.c: warning fixes
 
 Revision 1.347  1999/08/06 02:57:26  ajc
 * locate_host.c: use strdoop() and phree() instead of strdup() and free()
@@ -1186,4 +1191,3 @@ Sat Jul 11 00:20:48 EDT 1998 Nathan Bryant <bryant@cs.usm.maine.edu>
 
 Fri Jul 10 1998 Art Cancro <ajc@uncnsrd.mt-kisco.ny.us>
        * Initial CVS import 
-
index 5731e5d76b3809157c1b9d84c1508562cda1a600..bb1162bb3f4b68a73363ceacfb6a5d15ff9697da 100644 (file)
@@ -21,6 +21,7 @@
 #include "server.h"
 #include "locate_host.h"
 #include "config.h"
+#include "tools.h"
 
 void locate_host(char *tbuf, const struct in_addr *addr)
 {
@@ -55,7 +56,7 @@ void locate_host(char *tbuf, const struct in_addr *addr)
        for (; *ch->h_addr_list; ch->h_addr_list++)
                if (!memcmp(*ch->h_addr_list, addr,
                            sizeof *addr)) {
-                       safestrncpy(tbuf, ch->h_name, 24);
+                       safestrncpy(tbuf, ch->h_name, 25);
                        goto end;
                }
        goto bad_dns;           /* they were spoofing. report a numeric IP
@@ -67,5 +68,5 @@ void locate_host(char *tbuf, const struct in_addr *addr)
        end_critical_section(S_NETDB);
 #endif
 
-       tbuf[24] = 0;
+       tbuf[25] = 0;
 }
index 9a05a94b36842057cd276d20a628b799cf9f7d29..4e6fd24c56ad3bb6b0fdb84acd75fc3fd68194ff 100644 (file)
@@ -55,7 +55,7 @@ struct CtdlICQ_CL {
        DWORD uin;
        char name[32];
        DWORD status;
-       char host[25];
+       char host[26];
 };
 
 
index e702c50785ad1c396daf252ffe1d7f93a64a8e4a..f3bf452423cf502dd397f30e2747452a367cde9a 100644 (file)
@@ -63,7 +63,7 @@ struct CitContext {
        int cs_clienttyp;       /* client type code */
        int cs_clientver;       /* client version number */
        char cs_clientname[32]; /* name of client software */
-       char cs_host[25];       /* host logged in from */
+       char cs_host[26];       /* host logged in from */
 
        FILE *download_fp;      /* Fields relating to file transfer */
        FILE *upload_fp;