Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/keepassxreboot/keepassxc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/autotype/AutoType.cpp5
-rw-r--r--src/autotype/AutoTypeFilterLineEdit.cpp4
-rw-r--r--src/autotype/AutoTypeFilterLineEdit.h10
-rw-r--r--src/autotype/AutoTypeSelectDialog.cpp7
-rw-r--r--src/browser/BrowserService.cpp2
-rw-r--r--src/browser/BrowserSettings.cpp6
-rw-r--r--src/browser/HostInstaller.cpp6
-rw-r--r--src/cli/Command.cpp3
-rw-r--r--src/cli/Extract.cpp2
-rw-r--r--src/cli/keepassxc-cli.cpp3
-rw-r--r--src/core/Alloc.cpp2
-rw-r--r--src/core/Bootstrap.cpp2
-rw-r--r--src/core/Merger.cpp6
-rw-r--r--src/core/Tools.cpp3
-rw-r--r--src/core/Translator.h2
-rw-r--r--src/fdosecrets/objects/Collection.cpp4
-rw-r--r--src/fdosecrets/objects/Item.cpp4
-rw-r--r--src/fdosecrets/objects/Service.cpp6
-rw-r--r--src/gui/AboutDialog.cpp1
-rw-r--r--src/gui/ApplicationSettingsWidget.cpp2
-rw-r--r--src/gui/dbsettings/DatabaseSettingsWidgetBrowser.cpp12
-rw-r--r--src/gui/masterkey/KeyComponentWidget.h4
-rw-r--r--src/keys/FileKey.cpp4
-rw-r--r--src/keys/PasswordKey.cpp2
-rw-r--r--src/keys/YkChallengeResponseKey.cpp2
-rw-r--r--src/main.cpp3
-rw-r--r--tests/TestCli.cpp13
-rw-r--r--tests/TestMerge.cpp8
28 files changed, 65 insertions, 63 deletions
diff --git a/src/autotype/AutoType.cpp b/src/autotype/AutoType.cpp
index c5012f0a8..7366ebbec 100644
--- a/src/autotype/AutoType.cpp
+++ b/src/autotype/AutoType.cpp
@@ -619,9 +619,8 @@ bool AutoType::windowMatches(const QString& windowTitle, const QString& windowPa
if (windowPattern.startsWith("//") && windowPattern.endsWith("//") && windowPattern.size() >= 4) {
QRegExp regExp(windowPattern.mid(2, windowPattern.size() - 4), Qt::CaseInsensitive, QRegExp::RegExp2);
return (regExp.indexIn(windowTitle) != -1);
- }
- return WildcardMatcher(windowTitle).match(windowPattern);
-
+ }
+ return WildcardMatcher(windowTitle).match(windowPattern);
}
/**
diff --git a/src/autotype/AutoTypeFilterLineEdit.cpp b/src/autotype/AutoTypeFilterLineEdit.cpp
index 09b902e7a..d94292d26 100644
--- a/src/autotype/AutoTypeFilterLineEdit.cpp
+++ b/src/autotype/AutoTypeFilterLineEdit.cpp
@@ -18,7 +18,7 @@
#include "AutoTypeFilterLineEdit.h"
#include <QKeyEvent>
-void AutoTypeFilterLineEdit::keyPressEvent(QKeyEvent *event)
+void AutoTypeFilterLineEdit::keyPressEvent(QKeyEvent* event)
{
if (event->key() == Qt::Key_Up) {
emit keyUpPressed();
@@ -29,7 +29,7 @@ void AutoTypeFilterLineEdit::keyPressEvent(QKeyEvent *event)
}
}
-void AutoTypeFilterLineEdit::keyReleaseEvent(QKeyEvent *event)
+void AutoTypeFilterLineEdit::keyReleaseEvent(QKeyEvent* event)
{
if (event->key() == Qt::Key_Escape) {
emit escapeReleased();
diff --git a/src/autotype/AutoTypeFilterLineEdit.h b/src/autotype/AutoTypeFilterLineEdit.h
index 7e7169816..6f8ca570d 100644
--- a/src/autotype/AutoTypeFilterLineEdit.h
+++ b/src/autotype/AutoTypeFilterLineEdit.h
@@ -25,10 +25,14 @@ class AutoTypeFilterLineEdit : public QLineEdit
Q_OBJECT
public:
- AutoTypeFilterLineEdit(QWidget* widget) : QLineEdit(widget) {}
+ AutoTypeFilterLineEdit(QWidget* widget)
+ : QLineEdit(widget)
+ {
+ }
+
protected:
- virtual void keyPressEvent(QKeyEvent *event);
- virtual void keyReleaseEvent(QKeyEvent *event);
+ virtual void keyPressEvent(QKeyEvent* event);
+ virtual void keyReleaseEvent(QKeyEvent* event);
signals:
void keyUpPressed();
void keyDownPressed();
diff --git a/src/autotype/AutoTypeSelectDialog.cpp b/src/autotype/AutoTypeSelectDialog.cpp
index 6fa3af7e1..69f181765 100644
--- a/src/autotype/AutoTypeSelectDialog.cpp
+++ b/src/autotype/AutoTypeSelectDialog.cpp
@@ -27,9 +27,9 @@
#include <QDialogButtonBox>
#include <QHeaderView>
#include <QLabel>
-#include <QVBoxLayout>
#include <QLineEdit>
#include <QSortFilterProxyModel>
+#include <QVBoxLayout>
#include "autotype/AutoTypeSelectView.h"
#include "core/AutoTypeMatch.h"
@@ -77,7 +77,7 @@ AutoTypeSelectDialog::AutoTypeSelectDialog(QWidget* parent)
connect(m_view, SIGNAL(rejected()), SLOT(reject()));
// clang-format on
- QSortFilterProxyModel *proxy = qobject_cast<QSortFilterProxyModel*>(m_view->model());
+ QSortFilterProxyModel* proxy = qobject_cast<QSortFilterProxyModel*>(m_view->model());
if (proxy) {
proxy->setFilterKeyColumn(-1);
proxy->setFilterCaseSensitivity(Qt::CaseInsensitive);
@@ -146,10 +146,9 @@ void AutoTypeSelectDialog::matchRemoved()
}
}
-
void AutoTypeSelectDialog::filterList(QString filterString)
{
- QSortFilterProxyModel *proxy = qobject_cast<QSortFilterProxyModel*>(m_view->model());
+ QSortFilterProxyModel* proxy = qobject_cast<QSortFilterProxyModel*>(m_view->model());
if (proxy) {
proxy->setFilterWildcard(filterString);
if (!m_view->currentIndex().isValid()) {
diff --git a/src/browser/BrowserService.cpp b/src/browser/BrowserService.cpp
index 5dc769259..d9d1b7507 100644
--- a/src/browser/BrowserService.cpp
+++ b/src/browser/BrowserService.cpp
@@ -739,7 +739,7 @@ QList<Entry*> BrowserService::sortEntries(QList<Entry*>& pwEntries, const QStrin
|| ((QString::localeAwareCompare(left->attributes()->value(field),
right->attributes()->value(field))
== 0)
- && (QString::localeAwareCompare(left->attributes()->value("UserName"),
+ && (QString::localeAwareCompare(left->attributes()->value("UserName"),
right->attributes()->value("UserName"))
< 0));
});
diff --git a/src/browser/BrowserSettings.cpp b/src/browser/BrowserSettings.cpp
index dd74dc1cb..e1fc3a2da 100644
--- a/src/browser/BrowserSettings.cpp
+++ b/src/browser/BrowserSettings.cpp
@@ -240,13 +240,13 @@ void BrowserSettings::setVivaldiSupport(bool enabled)
bool BrowserSettings::braveSupport()
{
- return m_hostInstaller.checkIfInstalled(HostInstaller::SupportedBrowsers::BRAVE);
+ return m_hostInstaller.checkIfInstalled(HostInstaller::SupportedBrowsers::BRAVE);
}
void BrowserSettings::setBraveSupport(bool enabled)
{
- m_hostInstaller.installBrowser(
- HostInstaller::SupportedBrowsers::BRAVE, enabled, supportBrowserProxy(), customProxyLocation());
+ m_hostInstaller.installBrowser(
+ HostInstaller::SupportedBrowsers::BRAVE, enabled, supportBrowserProxy(), customProxyLocation());
}
bool BrowserSettings::torBrowserSupport()
diff --git a/src/browser/HostInstaller.cpp b/src/browser/HostInstaller.cpp
index 52da5e6c8..65dd63932 100644
--- a/src/browser/HostInstaller.cpp
+++ b/src/browser/HostInstaller.cpp
@@ -171,7 +171,7 @@ QString HostInstaller::getTargetPath(SupportedBrowsers browser) const
case SupportedBrowsers::TOR_BROWSER:
return TARGET_DIR_TOR_BROWSER;
case SupportedBrowsers::BRAVE:
- return TARGET_DIR_BRAVE;
+ return TARGET_DIR_BRAVE;
default:
return QString();
}
@@ -194,11 +194,11 @@ QString HostInstaller::getBrowserName(SupportedBrowsers browser) const
case SupportedBrowsers::FIREFOX:
return "firefox";
case SupportedBrowsers::VIVALDI:
- return "vivaldi";
+ return "vivaldi";
case SupportedBrowsers::TOR_BROWSER:
return "tor-browser";
case SupportedBrowsers::BRAVE:
- return "brave";
+ return "brave";
default:
return QString();
}
diff --git a/src/cli/Command.cpp b/src/cli/Command.cpp
index e64dd4aaa..48e1f4116 100644
--- a/src/cli/Command.cpp
+++ b/src/cli/Command.cpp
@@ -47,8 +47,7 @@ const QCommandLineOption Command::KeyFileOption = QCommandLineOption(QStringList
QObject::tr("path"));
const QCommandLineOption Command::NoPasswordOption =
- QCommandLineOption(QStringList() << "no-password",
- QObject::tr("Deactivate password key for the database."));
+ QCommandLineOption(QStringList() << "no-password", QObject::tr("Deactivate password key for the database."));
QMap<QString, Command*> commands;
diff --git a/src/cli/Extract.cpp b/src/cli/Extract.cpp
index 054a391bd..90713e1ec 100644
--- a/src/cli/Extract.cpp
+++ b/src/cli/Extract.cpp
@@ -56,7 +56,7 @@ int Extract::execute(const QStringList& arguments)
errorTextStream << parser.helpText().replace("[options]", "extract [options]");
return EXIT_FAILURE;
}
-
+
auto compositeKey = QSharedPointer<CompositeKey>::create();
auto db = Utils::unlockDatabase(args.at(0),
diff --git a/src/cli/keepassxc-cli.cpp b/src/cli/keepassxc-cli.cpp
index 2c6ce4660..1f76812b0 100644
--- a/src/cli/keepassxc-cli.cpp
+++ b/src/cli/keepassxc-cli.cpp
@@ -61,8 +61,7 @@ int main(int argc, char** argv)
parser.addPositionalArgument("command", QObject::tr("Name of the command to execute."));
- QCommandLineOption debugInfoOption(QStringList() << "debug-info",
- QObject::tr("Displays debugging information."));
+ QCommandLineOption debugInfoOption(QStringList() << "debug-info", QObject::tr("Displays debugging information."));
parser.addOption(debugInfoOption);
parser.addHelpOption();
parser.addVersionOption();
diff --git a/src/core/Alloc.cpp b/src/core/Alloc.cpp
index a33b56196..89d044ec3 100644
--- a/src/core/Alloc.cpp
+++ b/src/core/Alloc.cpp
@@ -78,7 +78,7 @@ void operator delete[](void* ptr) noexcept
* Custom insecure delete operator that does not zero out memory before
* freeing a buffer. Can be used for better performance.
*/
-void operator delete(void* ptr, bool) noexcept
+void operator delete(void* ptr, bool)noexcept
{
std::free(ptr);
}
diff --git a/src/core/Bootstrap.cpp b/src/core/Bootstrap.cpp
index 2d1a3e087..204942f4d 100644
--- a/src/core/Bootstrap.cpp
+++ b/src/core/Bootstrap.cpp
@@ -257,7 +257,7 @@ namespace Bootstrap
nullptr, // do not change owner or group
pACL, // DACL specified
nullptr // do not change SACL
- );
+ );
Cleanup:
diff --git a/src/core/Merger.cpp b/src/core/Merger.cpp
index dcbed250f..c70cd4b04 100644
--- a/src/core/Merger.cpp
+++ b/src/core/Merger.cpp
@@ -625,9 +625,9 @@ Merger::ChangeList Merger::mergeMetadata(const MergeContext& context)
// Merge Custom Data if source is newer
const auto targetCustomDataModificationTime = sourceMetadata->customData()->getLastModified();
const auto sourceCustomDataModificationTime = targetMetadata->customData()->getLastModified();
- if (!targetMetadata->customData()->contains(CustomData::LastModified) ||
- (targetCustomDataModificationTime.isValid() && sourceCustomDataModificationTime.isValid() &&
- targetCustomDataModificationTime > sourceCustomDataModificationTime)) {
+ if (!targetMetadata->customData()->contains(CustomData::LastModified)
+ || (targetCustomDataModificationTime.isValid() && sourceCustomDataModificationTime.isValid()
+ && targetCustomDataModificationTime > sourceCustomDataModificationTime)) {
const auto sourceCustomDataKeys = sourceMetadata->customData()->keys();
const auto targetCustomDataKeys = targetMetadata->customData()->keys();
diff --git a/src/core/Tools.cpp b/src/core/Tools.cpp
index 46cde95bc..beacbaaad 100644
--- a/src/core/Tools.cpp
+++ b/src/core/Tools.cpp
@@ -23,6 +23,7 @@
#include "core/Config.h"
#include "core/Translator.h"
+#include "git-info.h"
#include <QCoreApplication>
#include <QElapsedTimer>
#include <QIODevice>
@@ -33,7 +34,6 @@
#include <QSysInfo>
#include <QUuid>
#include <cctype>
-#include "git-info.h"
#ifdef Q_OS_WIN
#include <windows.h> // for Sleep()
@@ -75,7 +75,6 @@ namespace Tools
#endif
debugInfo.append("\n");
-
#if QT_VERSION >= QT_VERSION_CHECK(5, 4, 0)
debugInfo.append(QObject::tr("Operating system: %1\nCPU architecture: %2\nKernel: %3 %4")
.arg(QSysInfo::prettyProductName(),
diff --git a/src/core/Translator.h b/src/core/Translator.h
index cfc49d710..23a18422c 100644
--- a/src/core/Translator.h
+++ b/src/core/Translator.h
@@ -18,9 +18,9 @@
#ifndef KEEPASSX_TRANSLATOR_H
#define KEEPASSX_TRANSLATOR_H
+#include <QLocale>
#include <QPair>
#include <QString>
-#include <QLocale>
class Translator
{
diff --git a/src/fdosecrets/objects/Collection.cpp b/src/fdosecrets/objects/Collection.cpp
index 119ec4ad2..6926a6c20 100644
--- a/src/fdosecrets/objects/Collection.cpp
+++ b/src/fdosecrets/objects/Collection.cpp
@@ -157,8 +157,8 @@ namespace FdoSecrets
if (ret.isError()) {
return ret;
}
- return static_cast<qulonglong>(
- m_backend->database()->rootGroup()->timeInfo().creationTime().toMSecsSinceEpoch() / 1000);
+ return static_cast<qulonglong>(m_backend->database()->rootGroup()->timeInfo().creationTime().toMSecsSinceEpoch()
+ / 1000);
}
DBusReturn<qulonglong> Collection::modified() const
diff --git a/src/fdosecrets/objects/Item.cpp b/src/fdosecrets/objects/Item.cpp
index fa37564a2..18624bbdb 100644
--- a/src/fdosecrets/objects/Item.cpp
+++ b/src/fdosecrets/objects/Item.cpp
@@ -354,12 +354,12 @@ namespace FdoSecrets
return pathComponents.join('/');
}
- QString Item::encodeAttributeKey(const QString &key)
+ QString Item::encodeAttributeKey(const QString& key)
{
return QUrl::toPercentEncoding(key, "", "_:").replace('%', '_');
}
- QString Item::decodeAttributeKey(const QString &key)
+ QString Item::decodeAttributeKey(const QString& key)
{
return QString::fromUtf8(QByteArray::fromPercentEncoding(key.toLatin1(), '_'));
}
diff --git a/src/fdosecrets/objects/Service.cpp b/src/fdosecrets/objects/Service.cpp
index c15d4052c..cf9dfdbf7 100644
--- a/src/fdosecrets/objects/Service.cpp
+++ b/src/fdosecrets/objects/Service.cpp
@@ -66,8 +66,10 @@ namespace FdoSecrets
// Connect to service unregistered signal
m_serviceWatcher.reset(new QDBusServiceWatcher());
- connect(
- m_serviceWatcher.data(), &QDBusServiceWatcher::serviceUnregistered, this, &Service::dbusServiceUnregistered);
+ connect(m_serviceWatcher.data(),
+ &QDBusServiceWatcher::serviceUnregistered,
+ this,
+ &Service::dbusServiceUnregistered);
m_serviceWatcher->setConnection(QDBusConnection::sessionBus());
diff --git a/src/gui/AboutDialog.cpp b/src/gui/AboutDialog.cpp
index f37baedc0..7abd9059e 100644
--- a/src/gui/AboutDialog.cpp
+++ b/src/gui/AboutDialog.cpp
@@ -26,7 +26,6 @@
#include <QClipboard>
-
static const QString aboutMaintainers = R"(
<p><ul>
<li>Jonathan White (<a href="https://github.com/droidmonkey">droidmonkey</a>)</li>
diff --git a/src/gui/ApplicationSettingsWidget.cpp b/src/gui/ApplicationSettingsWidget.cpp
index 2461230c8..fce352237 100644
--- a/src/gui/ApplicationSettingsWidget.cpp
+++ b/src/gui/ApplicationSettingsWidget.cpp
@@ -97,7 +97,7 @@ ApplicationSettingsWidget::ApplicationSettingsWidget(QWidget* parent)
#else
m_generalUi->checkForUpdatesOnStartupCheckBox->setVisible(false);
m_generalUi->checkForUpdatesIncludeBetasCheckBox->setVisible(false);
- m_generalUi->checkUpdatesSpacer->changeSize(0,0, QSizePolicy::Fixed, QSizePolicy::Fixed);
+ m_generalUi->checkUpdatesSpacer->changeSize(0, 0, QSizePolicy::Fixed, QSizePolicy::Fixed);
#endif
#ifndef WITH_XC_NETWORKING
diff --git a/src/gui/dbsettings/DatabaseSettingsWidgetBrowser.cpp b/src/gui/dbsettings/DatabaseSettingsWidgetBrowser.cpp
index fac85c21e..4ea30c1f6 100644
--- a/src/gui/dbsettings/DatabaseSettingsWidgetBrowser.cpp
+++ b/src/gui/dbsettings/DatabaseSettingsWidgetBrowser.cpp
@@ -242,12 +242,12 @@ void DatabaseSettingsWidgetBrowser::convertAttributesToCustomData()
{
if (MessageBox::Yes
!= MessageBox::question(
- this,
- tr("Move KeePassHTTP attributes to custom data"),
- tr("Do you really want to move all legacy browser integration data to the latest standard?\n"
- "This is necessary to maintain compatibility with the browser plugin."),
- MessageBox::Yes | MessageBox::Cancel,
- MessageBox::Cancel)) {
+ this,
+ tr("Move KeePassHTTP attributes to custom data"),
+ tr("Do you really want to move all legacy browser integration data to the latest standard?\n"
+ "This is necessary to maintain compatibility with the browser plugin."),
+ MessageBox::Yes | MessageBox::Cancel,
+ MessageBox::Cancel)) {
return;
}
diff --git a/src/gui/masterkey/KeyComponentWidget.h b/src/gui/masterkey/KeyComponentWidget.h
index 63079863e..b73f881fc 100644
--- a/src/gui/masterkey/KeyComponentWidget.h
+++ b/src/gui/masterkey/KeyComponentWidget.h
@@ -18,9 +18,9 @@
#ifndef KEEPASSXC_KEYCOMPONENTWIDGET_H
#define KEEPASSXC_KEYCOMPONENTWIDGET_H
+#include <QPointer>
#include <QScopedPointer>
#include <QWidget>
-#include <QPointer>
namespace Ui
{
@@ -111,7 +111,7 @@ signals:
void componentRemovalRequested();
protected:
- void showEvent(QShowEvent* event) override ;
+ void showEvent(QShowEvent* event) override;
private slots:
void updateComponentName(const QString& name);
diff --git a/src/keys/FileKey.cpp b/src/keys/FileKey.cpp
index da25ef4ae..9c3d41c1d 100644
--- a/src/keys/FileKey.cpp
+++ b/src/keys/FileKey.cpp
@@ -24,10 +24,10 @@
#include <QFile>
-#include <sodium.h>
-#include <gcrypt.h>
#include <algorithm>
#include <cstring>
+#include <gcrypt.h>
+#include <sodium.h>
QUuid FileKey::UUID("a584cbc4-c9b4-437e-81bb-362ca9709273");
diff --git a/src/keys/PasswordKey.cpp b/src/keys/PasswordKey.cpp
index 2d0416af8..77d2f276e 100644
--- a/src/keys/PasswordKey.cpp
+++ b/src/keys/PasswordKey.cpp
@@ -19,9 +19,9 @@
#include "core/Tools.h"
#include "crypto/CryptoHash.h"
-#include <gcrypt.h>
#include <algorithm>
#include <cstring>
+#include <gcrypt.h>
QUuid PasswordKey::UUID("77e90411-303a-43f2-b773-853b05635ead");
diff --git a/src/keys/YkChallengeResponseKey.cpp b/src/keys/YkChallengeResponseKey.cpp
index 759d8d1bc..03328ef74 100644
--- a/src/keys/YkChallengeResponseKey.cpp
+++ b/src/keys/YkChallengeResponseKey.cpp
@@ -32,9 +32,9 @@
#include <QXmlStreamReader>
#include <QtConcurrent>
+#include <cstring>
#include <gcrypt.h>
#include <sodium.h>
-#include <cstring>
QUuid YkChallengeResponseKey::UUID("e092495c-e77d-498b-84a1-05ae0d955508");
diff --git a/src/main.cpp b/src/main.cpp
index 685a7a15c..b6769661b 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -82,8 +82,7 @@ int main(int argc, char** argv)
QCommandLineOption helpOption = parser.addHelpOption();
QCommandLineOption versionOption = parser.addVersionOption();
- QCommandLineOption debugInfoOption(QStringList() << "debug-info",
- QObject::tr("Displays debugging information."));
+ QCommandLineOption debugInfoOption(QStringList() << "debug-info", QObject::tr("Displays debugging information."));
parser.addOption(configOption);
parser.addOption(keyfileOption);
parser.addOption(pwstdinOption);
diff --git a/tests/TestCli.cpp b/tests/TestCli.cpp
index 9574f6d32..23af631e6 100644
--- a/tests/TestCli.cpp
+++ b/tests/TestCli.cpp
@@ -690,8 +690,9 @@ void TestCli::testKeyFileOption()
listCmd.execute({"ls", "-k", keyFilePath, m_keyFileProtectedDbFile->fileName()});
m_stdoutFile->reset();
m_stdoutFile->readLine(); // skip password prompt
- QCOMPARE(m_stdoutFile->readAll(), QByteArray("entry1\n"
- "entry2\n"));
+ QCOMPARE(m_stdoutFile->readAll(),
+ QByteArray("entry1\n"
+ "entry2\n"));
// Should raise an error with no key file.
qint64 pos = m_stdoutFile->pos();
@@ -713,8 +714,7 @@ void TestCli::testKeyFileOption()
m_stdoutFile->readLine(); // skip password prompt
m_stderrFile->seek(posErr);
QCOMPARE(m_stdoutFile->readAll(), QByteArray(""));
- QCOMPARE(m_stderrFile->readAll().split(':').at(0),
- QByteArray("Failed to load key file invalidpath"));
+ QCOMPARE(m_stderrFile->readAll().split(':').at(0), QByteArray("Failed to load key file invalidpath"));
}
void TestCli::testNoPasswordOption()
@@ -724,8 +724,9 @@ void TestCli::testNoPasswordOption()
QString keyFilePath(QString(KEEPASSX_TEST_DATA_DIR).append("/KeyFileProtectedNoPassword.key"));
listCmd.execute({"ls", "-k", keyFilePath, "--no-password", m_keyFileProtectedNoPasswordDbFile->fileName()});
m_stdoutFile->reset();
- QCOMPARE(m_stdoutFile->readAll(), QByteArray("entry1\n"
- "entry2\n"));
+ QCOMPARE(m_stdoutFile->readAll(),
+ QByteArray("entry1\n"
+ "entry2\n"));
// Should raise an error with no key file.
qint64 pos = m_stdoutFile->pos();
diff --git a/tests/TestMerge.cpp b/tests/TestMerge.cpp
index 4d9aef211..9fc353ddf 100644
--- a/tests/TestMerge.cpp
+++ b/tests/TestMerge.cpp
@@ -1172,7 +1172,7 @@ void TestMerge::testCustomdata()
QScopedPointer<Database> dbSource2(createTestDatabase());
m_clock->advanceSecond(1);
-
+
dbDestination->metadata()->customData()->set("toBeDeleted", "value");
dbDestination->metadata()->customData()->set("key3", "oldValue");
@@ -1212,7 +1212,8 @@ void TestMerge::testCustomdata()
QCOMPARE(dbDestination->metadata()->customData()->value("key1"), QString("value1"));
QCOMPARE(dbDestination->metadata()->customData()->value("key2"), QString("value2"));
QCOMPARE(dbDestination->metadata()->customData()->value("Browser"), QString("n'8=3W@L^6d->d.]St_>]"));
- QCOMPARE(dbDestination->metadata()->customData()->value("key3"), QString("newValue")); // Old value should be replaced
+ QCOMPARE(dbDestination->metadata()->customData()->value("key3"),
+ QString("newValue")); // Old value should be replaced
// Target is newer, no data is merged
QVERIFY(!dbDestination2->metadata()->customData()->isEmpty());
@@ -1220,7 +1221,8 @@ void TestMerge::testCustomdata()
QVERIFY(!dbDestination2->metadata()->customData()->contains("key2"));
QVERIFY(!dbDestination2->metadata()->customData()->contains("Browser"));
QVERIFY(dbDestination2->metadata()->customData()->contains("notToBeDeleted"));
- QCOMPARE(dbDestination2->metadata()->customData()->value("key3"), QString("oldValue")); // Old value should not be replaced
+ QCOMPARE(dbDestination2->metadata()->customData()->value("key3"),
+ QString("oldValue")); // Old value should not be replaced
}
void TestMerge::testDeletedEntry()