Commit f8345978 authored by Marcel Wiesweg's avatar Marcel Wiesweg
Browse files

Use a read lock when computing the file hash

parent 729399dc
......@@ -2827,6 +2827,7 @@ QByteArray DImg::getUniqueHash() const
return QByteArray();
}
FileReadLocker lock(filePath);
QByteArray hash = DImgLoader::uniqueHash(filePath, *this, false);
// attribute is written by DImgLoader
......@@ -2859,6 +2860,7 @@ QByteArray DImg::getUniqueHashV2() const
return QByteArray();
}
FileReadLocker lock(filePath);
return DImgLoader::uniqueHashV2(filePath, this);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment