aboutsummaryrefslogtreecommitdiff
path: root/lib/file.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2000-02-14 22:57:42 +0000
committerDaniel Stenberg <daniel@haxx.se>2000-02-14 22:57:42 +0000
commit5a99be254566758d8ff42d905cad98b1ee7a2e87 (patch)
treefc1661b871bdbcd45a6ca3c8a8206e0f9342022f /lib/file.c
parentefb410a188fb7f5a9f1d572db1d98b5e3c790a83 (diff)
updated to use the new set of progress-functions
Diffstat (limited to 'lib/file.c')
-rw-r--r--lib/file.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/file.c b/lib/file.c
index b5d198e57..99759f477 100644
--- a/lib/file.c
+++ b/lib/file.c
@@ -145,7 +145,12 @@ UrgError file(struct UrlData *data, char *path, long *bytecountp)
this is both more efficient than the former call to download() and
it avoids problems with select() and recv() on file descriptors
in Winsock */
+#if 0
ProgressInit (data, expected_size);
+#endif
+ if(expected_size != -1)
+ pgrsSetDownloadSize(data, expected_size);
+
while (1) {
nread = read(fd, buf, BUFSIZE-1);
@@ -164,10 +169,16 @@ UrgError file(struct UrlData *data, char *path, long *bytecountp)
return URG_WRITE_ERROR;
}
now = tvnow();
+ pgrsUpdate(data);
+#if 0
ProgressShow (data, bytecount, start, now, FALSE);
+#endif
}
now = tvnow();
+#if 0
ProgressShow (data, bytecount, start, now, TRUE);
+#endif
+ pgrsUpdate(data);
close(fd);