mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-08-09 15:02:39 -04:00
Improve code style.
This commit is contained in:
parent
4e5e5c71ca
commit
2e011d5362
29 changed files with 95 additions and 89 deletions
|
@ -17,11 +17,11 @@
|
|||
|
||||
#include "CompositeKey.h"
|
||||
|
||||
#include <QtCore/QtConcurrentRun>
|
||||
|
||||
#include "crypto/CryptoHash.h"
|
||||
#include "crypto/SymmetricCipher.h"
|
||||
|
||||
#include <QtCore/QtConcurrentRun>
|
||||
|
||||
CompositeKey::CompositeKey()
|
||||
{
|
||||
}
|
||||
|
@ -90,7 +90,7 @@ QByteArray CompositeKey::transformKeyRaw(const QByteArray& key, const QByteArray
|
|||
|
||||
QByteArray result = key;
|
||||
|
||||
for (int i=0; i<rounds; i++) {
|
||||
for (int i = 0; i < rounds; i++) {
|
||||
cipher.processInPlace(result);
|
||||
}
|
||||
|
||||
|
|
|
@ -34,39 +34,39 @@ bool FileKey::load(QIODevice* device)
|
|||
return false;
|
||||
}
|
||||
|
||||
if (device->size() == 0) {
|
||||
return false;
|
||||
}
|
||||
if (device->size() == 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadXml(device)) {
|
||||
return true;
|
||||
}
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadXml(device)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadBinary(device)) {
|
||||
return true;
|
||||
}
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadBinary(device)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadHex(device)) {
|
||||
return true;
|
||||
}
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadHex(device)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadHashed(device)) {
|
||||
return true;
|
||||
}
|
||||
if (!device->reset()) {
|
||||
return false;
|
||||
}
|
||||
if (loadHashed(device)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool FileKey::load(const QString& fileName, QString* errorMsg)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue