mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-08-03 03:56:08 -04:00
Add braces around single line statements
* Ran clang-tidy with "readability-braces-around-statements" to find missing braces around statements.
This commit is contained in:
parent
c427000184
commit
c663b5d5fc
12 changed files with 98 additions and 54 deletions
|
@ -30,8 +30,9 @@ void TestCsvParser::initTestCase()
|
|||
void TestCsvParser::init()
|
||||
{
|
||||
file.reset(new QTemporaryFile());
|
||||
if (not file->open())
|
||||
if (not file->open()) {
|
||||
QFAIL("Cannot open file!");
|
||||
}
|
||||
parser->setBackslashSyntax(false);
|
||||
parser->setComment('#');
|
||||
parser->setFieldSeparator(',');
|
||||
|
|
|
@ -289,14 +289,16 @@ void TestSymmetricCipher::testTwofish256CbcEncryption()
|
|||
QCOMPARE(cipher.blockSize(), 16);
|
||||
for (int j = 0; j < 5000; ++j) {
|
||||
ctCur = cipher.process(ptNext, &ok);
|
||||
if (!ok)
|
||||
if (!ok) {
|
||||
break;
|
||||
}
|
||||
ptNext = ctPrev;
|
||||
ctPrev = ctCur;
|
||||
|
||||
ctCur = cipher.process(ptNext, &ok);
|
||||
if (!ok)
|
||||
if (!ok) {
|
||||
break;
|
||||
}
|
||||
ptNext = ctPrev;
|
||||
ctPrev = ctCur;
|
||||
}
|
||||
|
@ -342,13 +344,15 @@ void TestSymmetricCipher::testTwofish256CbcDecryption()
|
|||
QCOMPARE(cipher.blockSize(), 16);
|
||||
for (int j = 0; j < 5000; ++j) {
|
||||
ptCur = cipher.process(ctNext, &ok);
|
||||
if (!ok)
|
||||
if (!ok) {
|
||||
break;
|
||||
}
|
||||
ctNext = ptCur;
|
||||
|
||||
ptCur = cipher.process(ctNext, &ok);
|
||||
if (!ok)
|
||||
if (!ok) {
|
||||
break;
|
||||
}
|
||||
ctNext = ptCur;
|
||||
}
|
||||
|
||||
|
|
|
@ -84,12 +84,14 @@ void TestYubiKeyChalResp::ykDetected(int slot, bool blocking)
|
|||
{
|
||||
Q_UNUSED(blocking);
|
||||
|
||||
if (slot > 0)
|
||||
if (slot > 0) {
|
||||
m_detected++;
|
||||
}
|
||||
|
||||
/* Key used for later testing */
|
||||
if (!m_key)
|
||||
if (!m_key) {
|
||||
m_key.reset(new YkChallengeResponseKey(slot, blocking));
|
||||
}
|
||||
}
|
||||
|
||||
void TestYubiKeyChalResp::deinit()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue