From 07d7a44731afba32008273e8c2137d08c79fcb15 Mon Sep 17 00:00:00 2001 From: Christophe Dumez Date: Wed, 12 Dec 2007 12:23:38 +0000 Subject: [PATCH] - DownloadThread now write in binary mode (should fix problems on Windows) --- src/downloadThread.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/downloadThread.cpp b/src/downloadThread.cpp index 16d2a8f1d..8d31fdd86 100644 --- a/src/downloadThread.cpp +++ b/src/downloadThread.cpp @@ -73,7 +73,7 @@ void subDownloadThread::run(){ filePath = tmpfile->fileName(); } delete tmpfile; - FILE *f = fopen(filePath.toUtf8().data(), "w"); + FILE *f = fopen(filePath.toUtf8().data(), "wb"); if(!f) { std::cerr << "couldn't open destination file" << "\n"; return; @@ -113,7 +113,7 @@ void subDownloadThread::run(){ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, fwrite); curl_easy_setopt(curl, CURLOPT_WRITEDATA, f); // Verbose - //curl_easy_setopt(curl, CURLOPT_VERBOSE, 1); + curl_easy_setopt(curl, CURLOPT_VERBOSE, 1); // No progress info (we don't use it) curl_easy_setopt(curl, CURLOPT_NOPROGRESS, 1); // Redirections