/[rdesktop]/sourceforge.net/trunk/rdesktop/tcp.c
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /sourceforge.net/trunk/rdesktop/tcp.c

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

revision 443 by astrand, Sun Aug 17 07:28:53 2003 UTC revision 546 by astrand, Sat Nov 8 09:17:41 2003 UTC
# Line 112  tcp_recv(STREAM s, uint32 length) Line 112  tcp_recv(STREAM s, uint32 length)
112                          return NULL;                          return NULL;
113    
114                  rcvd = recv(sock, s->end, length, 0);                  rcvd = recv(sock, s->end, length, 0);
115                  if (rcvd <= 0)                  if (rcvd < 0)
116                  {                  {
117                          error("recv: %s\n", strerror(errno));                          error("recv: %s\n", strerror(errno));
118                          return NULL;                          return NULL;
119                  }                  }
120                    else if (rcvd == 0)
121                    {
122                            error("Connection closed\n");
123                            return NULL;
124                    }
125    
126                  s->end += rcvd;                  s->end += rcvd;
127                  length -= rcvd;                  length -= rcvd;

Legend:
Removed from v.443  
changed lines
  Added in v.546

  ViewVC Help
Powered by ViewVC 1.1.26