diff options
author | Yang Tse <yangsita@gmail.com> | 2006-07-12 05:19:00 +0000 |
---|---|---|
committer | Yang Tse <yangsita@gmail.com> | 2006-07-12 05:19:00 +0000 |
commit | 58176d14848f315ea74772bd9ce7edd847b2a17d (patch) | |
tree | 42685c540585d5c2d1205176734da6f2a54222e4 /tests/server | |
parent | 10489879f731465f3d2105870e7533c2b355af5d (diff) |
Use platform's native types for recv() and send() arguments.
Diffstat (limited to 'tests/server')
-rw-r--r-- | tests/server/sockfilt.c | 3 | ||||
-rw-r--r-- | tests/server/sws.c | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/tests/server/sockfilt.c b/tests/server/sockfilt.c index eec0cd39f..636132615 100644 --- a/tests/server/sockfilt.c +++ b/tests/server/sockfilt.c @@ -173,6 +173,7 @@ static int juggle(curl_socket_t *sockfdp, unsigned char buffer[256]; /* FIX: bigger buffer */ char data[256]; curl_socket_t sockfd; + ssize_t bytes_written; timeout.tv_sec = 120; timeout.tv_usec = 0; @@ -301,7 +302,7 @@ static int juggle(curl_socket_t *sockfdp, } else /* send away on the socket */ - swrite(sockfd, buffer, len); + bytes_written = swrite(sockfd, buffer, len); } else if(!memcmp("DISC", buffer, 4)) { /* disconnect! */ diff --git a/tests/server/sws.c b/tests/server/sws.c index 95429dfcd..3eff97d45 100644 --- a/tests/server/sws.c +++ b/tests/server/sws.c @@ -493,7 +493,7 @@ static int get_request(int sock, struct httprequest *req) /* returns -1 on failure */ static int send_doc(int sock, struct httprequest *req) { - int written; + ssize_t written; size_t count; const char *buffer; char *ptr; @@ -519,7 +519,7 @@ static int send_doc(int sock, struct httprequest *req) count = strlen(STREAMTHIS); while(1) { written = swrite(sock, STREAMTHIS, count); - if(written != (int)count) { + if(written != count) { logmsg("Stopped streaming"); break; } |