Windows: Fix rename of finished file. #3073

The file was still open and therefore couldn't be renamed...
This commit is contained in:
Christian Kamm 2015-04-22 14:45:01 +02:00
parent 60729f2bbd
commit 7c1281dd06

View file

@ -339,6 +339,7 @@ void PropagateDownloadFileQNAM::start()
if (startSize > 0) {
if (startSize == _item._size) {
qDebug() << "File is already complete, no need to download";
_tmpFile.close();
downloadFinished();
return;
}
@ -489,7 +490,6 @@ QString makeConflictFileName(const QString &fn, const QDateTime &dt)
void PropagateDownloadFileQNAM::downloadFinished()
{
QString fn = _propagator->getFilePath(_item._file);
// In case of file name clash, report an error