aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2008-01-11 17:35:10 +0000
committerYang Tse <yangsita@gmail.com>2008-01-11 17:35:10 +0000
commit3564aec388ee0c0177849389bb136461cc95ee62 (patch)
treed2ced7d6c8021b0eb84ec8eb242e4339e7bc368e
parenta0420904678c3f084790a19ce8cc8cbce76cb353 (diff)
fix compiler warning
-rw-r--r--lib/ftp.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/ftp.c b/lib/ftp.c
index af0fc2f00..931aba479 100644
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -403,7 +403,7 @@ static CURLcode ftp_readresp(curl_socket_t sockfd,
int *ftpcode, /* return the ftp-code if done */
size_t *size) /* size of the response */
{
- int perline; /* count bytes per line */
+ ssize_t perline; /* count bytes per line */
bool keepon=TRUE;
ssize_t gotbytes;
char *ptr;
@@ -418,8 +418,9 @@ static CURLcode ftp_readresp(curl_socket_t sockfd,
ptr=buf + ftpc->nread_resp;
- perline= (int)(ptr-ftpc->linestart_resp); /* number of bytes in the current
- line, so far */
+ /* number of bytes in the current line, so far */
+ perline = (ssize_t)(ptr-ftpc->linestart_resp);
+
keepon=TRUE;
while((ftpc->nread_resp<BUFSIZE) && (keepon && !result)) {
@@ -479,7 +480,7 @@ static CURLcode ftp_readresp(curl_socket_t sockfd,
* byte to a set of lines and possible just a piece of the last
* line */
ssize_t i;
- int clipamount = 0;
+ ssize_t clipamount = 0;
bool restart = FALSE;
data->req.headerbytecount += gotbytes;