use double where it is supposed to
authorDaniel Stenberg <daniel@haxx.se>
Mon, 22 Apr 2002 23:54:43 +0000 (23:54 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Mon, 22 Apr 2002 23:54:43 +0000 (23:54 +0000)
lib/file.c

index e84cd4ce276f031bf2c86943489f03f31205651f..4515d9d94c8d18da2aee1bd4ff70e3de20284c94 100644 (file)
@@ -140,7 +140,7 @@ CURLcode Curl_file(struct connectdata *conn)
   */
   CURLcode res = CURLE_OK;
   struct stat statbuf;
-  ssize_t expected_size=-1;
+  double expected_size=-1;
   ssize_t nread;
   struct SessionHandle *data = conn->data;
   char *buf = data->state.buffer;
@@ -155,7 +155,7 @@ CURLcode Curl_file(struct connectdata *conn)
 /*VMS?? -- This only works reliable for STREAMLF files */
   if( -1 != fstat(fd, &statbuf)) {
     /* we could stat it, then read out the size */
-    expected_size = statbuf.st_size;
+    expected_size = (double)statbuf.st_size;
   }
 
   /* The following is a shortcut implementation of file reading