summaryrefslogtreecommitdiffstats
path: root/copyworker.cpp
diff options
context:
space:
mode:
authorArno <arno@disconnect.de>2022-04-15 13:27:34 +0200
committerArno <arno@disconnect.de>2022-04-15 13:27:34 +0200
commit856119c5a43b4781b051b93a0713c152cfd99f85 (patch)
tree4e2fde4e7a76179cc243e0665091c6ad429ea640 /copyworker.cpp
parent62d3ca1482b202d2883eeb5e17e72300e8612477 (diff)
downloadSheMov-856119c5a43b4781b051b93a0713c152cfd99f85.tar.gz
SheMov-856119c5a43b4781b051b93a0713c152cfd99f85.tar.bz2
SheMov-856119c5a43b4781b051b93a0713c152cfd99f85.zip
Make it run with Qt6
This is a huge commit. Changes: * Obviously, make it compile * Make it run (only scarcely tested) * get rid of most of clang's warnings Let's see what surprises are in store...
Diffstat (limited to 'copyworker.cpp')
-rw-r--r--copyworker.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/copyworker.cpp b/copyworker.cpp
index 0fbc802..22e62f4 100644
--- a/copyworker.cpp
+++ b/copyworker.cpp
@@ -15,7 +15,7 @@ CopyWorker::CopyWorker(QObject *parent) : QThread(parent), mMax(0) {}
void CopyWorker::enqueue(const QString &source, const QString &destination){
QMutexLocker l(&mSourceMx);
- QPair<QString, QString> x = qMakePair<QString, QString>(source, destination);
+ std::pair<QString, QString> x(source, destination);
if(!mFiles.contains(x)){
QFileInfo fi(source);
mFiles.append(x);
@@ -74,7 +74,7 @@ void CopyWorker::run(){
qint64 cur = total / 1024 / 1024;
emit bytesRead(cur);
}
- delete buf;
+ delete[] buf;
}
QString s = QString(tr("Done copying %1 file(s)")).arg(QString::number(mFiles.size()));
emit success(s);