From 5b240dd94561bef6a030b25cfa70838053ad53b2 Mon Sep 17 00:00:00 2001 From: Thomas Preud'homme Date: Thu, 1 Mar 2018 22:39:56 +0000 Subject: New upstream version 1.4.0.4 --- plugins/CopyEngine/Rsync/informations.xml | 2 +- plugins/CopyEngine/Ultracopier/DriveManagement.cpp | 1 + plugins/CopyEngine/Ultracopier/ListThread.cpp | 25 +++++++++++----------- plugins/CopyEngine/Ultracopier/informations.xml | 2 +- 4 files changed, 15 insertions(+), 15 deletions(-) (limited to 'plugins/CopyEngine') diff --git a/plugins/CopyEngine/Rsync/informations.xml b/plugins/CopyEngine/Rsync/informations.xml index 46cbf7e..17c9f26 100644 --- a/plugins/CopyEngine/Rsync/informations.xml +++ b/plugins/CopyEngine/Rsync/informations.xml @@ -14,7 +14,7 @@ - 1.4.0.3 + 1.4.0.4 Rsync diff --git a/plugins/CopyEngine/Ultracopier/DriveManagement.cpp b/plugins/CopyEngine/Ultracopier/DriveManagement.cpp index 8deaf3c..f25836f 100644 --- a/plugins/CopyEngine/Ultracopier/DriveManagement.cpp +++ b/plugins/CopyEngine/Ultracopier/DriveManagement.cpp @@ -19,6 +19,7 @@ DriveManagement::DriveManagement() } //get drive of an file or folder +/// \todo do network drive support for windows std::string DriveManagement::getDrive(const std::string &fileOrFolder) const { const std::string &inode=QDir::toNativeSeparators(QString::fromStdString(fileOrFolder)).toStdString(); diff --git a/plugins/CopyEngine/Ultracopier/ListThread.cpp b/plugins/CopyEngine/Ultracopier/ListThread.cpp index 4b9cde5..8d47326 100644 --- a/plugins/CopyEngine/Ultracopier/ListThread.cpp +++ b/plugins/CopyEngine/Ultracopier/ListThread.cpp @@ -1160,21 +1160,20 @@ uint64_t ListThread::addToTransfer(const QFileInfo& source,const QFileInfo& dest if(!source.isSymLink()) size=source.size(); const std::string &drive=driveManagement.getDrive(destination.absoluteFilePath().toStdString()); - if(drive.empty()) - abort(); - if(mode!=Ultracopier::Move || drive!=driveManagement.getDrive(source.absoluteFilePath().toStdString())) - { - if(requiredSpace.find(drive)!=requiredSpace.cend()) + if(!drive.empty())//can be a network drive + if(mode!=Ultracopier::Move || drive!=driveManagement.getDrive(source.absoluteFilePath().toStdString())) { - requiredSpace[drive]+=size; - ULTRACOPIER_DEBUGCONSOLE(Ultracopier::DebugLevel_Notice,QStringLiteral("space needed add: %1, space needed: %2, on: %3").arg(size).arg(requiredSpace.at(drive)).arg(QString::fromStdString(drive)).toStdString()); - } - else - { - requiredSpace[drive]=size; - ULTRACOPIER_DEBUGCONSOLE(Ultracopier::DebugLevel_Notice,QStringLiteral("set space %1 needed, on: %2").arg(size).arg(QString::fromStdString(drive)).toStdString()); + if(requiredSpace.find(drive)!=requiredSpace.cend()) + { + requiredSpace[drive]+=size; + ULTRACOPIER_DEBUGCONSOLE(Ultracopier::DebugLevel_Notice,QStringLiteral("space needed add: %1, space needed: %2, on: %3").arg(size).arg(requiredSpace.at(drive)).arg(QString::fromStdString(drive)).toStdString()); + } + else + { + requiredSpace[drive]=size; + ULTRACOPIER_DEBUGCONSOLE(Ultracopier::DebugLevel_Notice,QStringLiteral("set space %1 needed, on: %2").arg(size).arg(QString::fromStdString(drive)).toStdString()); + } } - } bytesToTransfer+= size; ActionToDoTransfer temp; temp.id = generateIdNumber(); diff --git a/plugins/CopyEngine/Ultracopier/informations.xml b/plugins/CopyEngine/Ultracopier/informations.xml index 61e04e0..7968ca8 100644 --- a/plugins/CopyEngine/Ultracopier/informations.xml +++ b/plugins/CopyEngine/Ultracopier/informations.xml @@ -17,7 +17,7 @@ - 1.4.0.3 + 1.4.0.4 Ultracopier -- cgit v1.2.3