cURL / Mailing Lists / curl-users / Single Mail

curl-users

curl (on Windows Vista 64 Bit edition) does only write partial file when doing download via redirect

From: Martin Maurer <meinemailingliste_at_online.de>
Date: Wed, 1 Jun 2011 13:12:29 +0200

Hello,

i am using

curl 7.21.6 (i386-pc-win32) libcurl/7.21.6 zlib/1.2.5
Protocols: dict file ftp gopher http imap ldap pop3 rtsp smtp telnet tftp
Features: AsynchDNS IPv6 Largefile libz

on Windows Vista 64 Bit edition.

I am calling curl as following:

once

curl http://192.168.178.145/ab/cde/fg/hijk.js > hijk.org

and later multiple times

curl http://192.168.178.145/ab/cde/fg/hijk.js > hijk.js
fc hijk.org hijk.js

I downloaded file hijk.js is equal to original file, i do the second url call again (i do this via batch file).

Around every two hours i see that hijk.js is a bit too small. curl itself reports the amount of bytes, which the original file had.
The written content seems to be on a 4 KByte (not completely sure, but at least on a 1 KByte boundary).
The last pieces from boundary to end of file is missing. It looks like writing to stdout which is redirected to hijk.js is not yet complete, when file compare is done.
According to wireshark it looks like the file was completely downloaded, with no error, also the last missing content is displayed as correctly transfered.
This leads me to the opinion, that something on PC side is not working.

Is there perhaps a flush missing ?

I am currently trying the following call instead:

curl -D log -o hijk.js -v -S http://192.168.178.145/ab/cde/fg/hijk.js

and the error has not occured yet. But it is too early to say, this way, it is working.

Best regards,

Martin

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-06-01