]> granicus.if.org Git - curl/commitdiff
TFTP: fix compiler warning
authorDaniel Stenberg <daniel@haxx.se>
Tue, 8 Jun 2010 08:35:06 +0000 (10:35 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 8 Jun 2010 08:35:06 +0000 (10:35 +0200)
Curl_fillreadbuffer()'s second argument takes an int, so
typecasting to another is a bad idea.

lib/tftp.c

index c09aadc03ee8b41e57d67af433b1d790ef54f1d9..c02337f99d3ee33708cd3315ef623d0d6ebd6500 100644 (file)
@@ -759,8 +759,7 @@ static CURLcode tftp_tx(tftp_state_data_t *state, tftp_event_t event)
       state->state = TFTP_STATE_FIN;
       return CURLE_OK;
     }
-    res = Curl_fillreadbuffer(state->conn, (size_t)state->blksize,
-                              &state->sbytes);
+    res = Curl_fillreadbuffer(state->conn, state->blksize, &state->sbytes);
     if(res)
       return res;
     sbytes = sendto(state->sockfd, (void *)state->spacket.data,