diff options
Diffstat (limited to 'helper.cpp')
-rw-r--r-- | helper.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -13,6 +13,7 @@ #include <QCryptographicHash> #include <QHash> #include <QSettings> +#include <QDir> #include "helper.h" @@ -90,6 +91,10 @@ namespace Helper { return QString(); } } + QFileInfo destDir = QFileInfo(destFile.absolutePath()); + if(!destDir.exists()){ + QDir::root().mkpath(destFile.absolutePath()); + } bool success = QFile::rename(path, destFile.absoluteFilePath()); if(success){ return destFile.absoluteFilePath(); |