Difference for socket/item.c from version 1.2 to 1.3


version 1.2 version 1.3
Line 1
 
Line 1
   
 /*  /*
  * static char *rcsid_item_c =   * static char *rcsid_item_c =
  *    "$Id: item.c,v 1.2 2000/05/23 07:06:32 cvs Exp $";   *    "$Id: item.c,v 1.3 2000/05/24 05:48:51 cvs Exp $";
  */   */
   
 /*  /*
Line 39
 
Line 39
 #include <newserver.h>  #include <newserver.h>
 #include <sproto.h>  #include <sproto.h>
   
   /* This is the maximum number of bytes we expect any one item to take up */
   #define MAXITEMLEN  300
   
 /*******************************************************************************  /*******************************************************************************
  *   *
Line 179
 
Line 181
      add_stringlen_to_sockbuf(query_short_name(tmp), &sl);       add_stringlen_to_sockbuf(query_short_name(tmp), &sl);
      got_one++;       got_one++;
      SET_FLAG(tmp, FLAG_CLIENT_SENT);       SET_FLAG(tmp, FLAG_CLIENT_SENT);
      if (sl.len > (MAXSOCKBUF-250)) {       if (sl.len > (MAXSOCKBUF-MAXITEMLEN)) {
  Send_With_Handling(&pl->contr->socket, &sl);   Send_With_Handling(&pl->contr->socket, &sl);
  strcpy((char*)sl.buf,"item ");   strcpy((char*)sl.buf,"item ");
  sl.len=strlen((char*)sl.buf);   sl.len=strlen((char*)sl.buf);
Line 249
 
Line 251
       * items (especially with some of the bags out there) to        * items (especially with some of the bags out there) to
       * overflow the buffer.  IF so, send multiple item1 commands.        * overflow the buffer.  IF so, send multiple item1 commands.
       */        */
      if (sl.len > (MAXSOCKBUF-250)) {       if (sl.len > (MAXSOCKBUF-MAXITEMLEN)) {
  Send_With_Handling(&pl->contr->socket, &sl);   Send_With_Handling(&pl->contr->socket, &sl);
  strcpy((char*)sl.buf,"item1 ");   strcpy((char*)sl.buf,"item1 ");
  sl.len=strlen((char*)sl.buf);   sl.len=strlen((char*)sl.buf);


Legend:
line(s) removed in v.1.2 
line(s) changed
 line(s) added in v.1.3

File made using version 1.98 of cvs2html by leaf at 2011-07-21 19:35