/[cvs]/eggdrop1.8/src/net.c
ViewVC logotype

Diff of /eggdrop1.8/src/net.c

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.9 by pseudo, Fri Nov 26 13:20:29 2010 UTC revision 1.10 by pseudo, Thu Feb 3 15:44:11 2011 UTC
# Line 726  int sockread(char *s, int *len, sock_lis Line 726  int sockread(char *s, int *len, sock_lis
726               SELECT_TYPE_ARG234 (have_w ? &fdw : NULL),               SELECT_TYPE_ARG234 (have_w ? &fdw : NULL),
727               SELECT_TYPE_ARG234 (have_e ? &fde : NULL),               SELECT_TYPE_ARG234 (have_e ? &fde : NULL),
728               SELECT_TYPE_ARG5 &t);               SELECT_TYPE_ARG5 &t);
729    if (x > 0) {    if (x == -1)
730      /* Something happened */      return -2;                  /* socket error */
731    
732      for (i = 0; i < slistmax; i++) {      for (i = 0; i < slistmax; i++) {
733        if (!tclonly && ((!(slist[i].flags & (SOCK_UNUSED | SOCK_TCL))) &&        if (!tclonly && ((!(slist[i].flags & (SOCK_UNUSED | SOCK_TCL))) &&
734            ((FD_ISSET(slist[i].sock, &fdr)) ||            ((FD_ISSET(slist[i].sock, &fdr)) ||
# Line 832  int sockread(char *s, int *len, sock_lis Line 833  int sockread(char *s, int *len, sock_lis
833            tclsock = i;            tclsock = i;
834        }        }
835      }      }
836    } else if (x == -1)    if (!tclonly) {
     return -2;                  /* socket error */  
   else if (!tclonly) {  
837      s[0] = 0;      s[0] = 0;
838      *len = 0;      *len = 0;
839    }    }

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.10

webmaster@eggheads.org
ViewVC Help
Powered by ViewVC 1.1.23