]> code.citadel.org Git - citadel.git/commitdiff
stupid me. I didn't realize that asking for the header did what I wanted
authorStu Mark <theeverything@citadel.org>
Sat, 29 Dec 2001 04:21:22 +0000 (04:21 +0000)
committerStu Mark <theeverything@citadel.org>
Sat, 29 Dec 2001 04:21:22 +0000 (04:21 +0000)
so I changed my little 'y' hack to not bother reading the text of the
message. a little saving on the bandwidth.

citadel/ChangeLog
citadel/messages.c

index 121f07204800b08517ed80d13ed69e8621114bcf..38ec282e671f9007f112f7bb5069eda6b1a80d09 100644 (file)
@@ -1,4 +1,9 @@
  $Log$
+ Revision 590.23  2001/12/29 04:21:22  nixo
+ stupid me. I didn't realize that asking for the header did what I wanted
+ so I changed my little 'y' hack to not bother reading the text of the
+ message. a little saving on the bandwidth.
+
  Revision 590.22  2001/12/28 22:32:38  nixo
  Added a "read m<y> next" function in read mode. It will skip to the next
  message by the user in the current message list (whatever mode you're in
@@ -3020,4 +3025,3 @@ Sat Jul 11 00:20:48 EDT 1998 Nathan Bryant <bryant@cs.usm.maine.edu>
 
 Fri Jul 10 1998 Art Cancro <ajc@uncensored.citadel.org>
        * Initial CVS import 
-
index e79881f16cc86fad1e0c2f750ec911479d2cc399..7f9dd8d65e104fd2e178a8501e528d9471ff7cf3 100644 (file)
@@ -1419,10 +1419,10 @@ RMSGREAD:       fflush(stdout);
                 char buf[SIZ];
                 int founda = 0;
                 
-                       sprintf(buf, "MSG0 %ld|%d", msg_arr[finda], 0); /* read whole message so we can get 'from=' */
+                       sprintf(buf, "MSG0 %ld|%d", msg_arr[finda], 1); /* read the header so we can get 'from=' */
                serv_puts(buf);
                serv_gets(buf);
-               while (serv_gets(buf), strncasecmp(buf, "text", 4)) 
+               while (serv_gets(buf), strcmp(buf, "000")) 
                   {
                        if ((!strncasecmp(buf, "from=", 5)) && (finda != a)) /* Skip current message. */
                      { 
@@ -1430,14 +1430,9 @@ RMSGREAD:        fflush(stdout);
                           {
                             a = lasta; /* meesa current */
                             founda = 1;
-                            break; /* while */
                           }
                          }
                  }
-                /* Now read the content of the message > /dev/null */
-                       while (serv_gets(buf), strcmp(buf, "000")) 
-                     {
-                         }
                    // we are now in synch with the server
                 if (founda)
                   break; /* for */