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

github.com/nextcloud/desktop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCamila San <hello@camila.codes>2020-05-29 16:07:05 +0300
committerKevin Ottens (Rebase PR Action) <er-vin@users.noreply.github.com>2020-06-03 10:50:40 +0300
commit3bae570f29e8c53386d35b0d2f33cbe6b435c0c7 (patch)
tree93a231d526d0ae70fccb9000e4eeeedf0e423d7c /src/gui/selectivesyncdialog.cpp
parente90eb9d717183776b3232bbe09b8e7907ca937c2 (diff)
Do not declare local variables without an initial value.
Signed-off-by: Camila San <hello@camila.codes>
Diffstat (limited to 'src/gui/selectivesyncdialog.cpp')
-rw-r--r--src/gui/selectivesyncdialog.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/selectivesyncdialog.cpp b/src/gui/selectivesyncdialog.cpp
index 8ee353fbe..b30258317 100644
--- a/src/gui/selectivesyncdialog.cpp
+++ b/src/gui/selectivesyncdialog.cpp
@@ -433,7 +433,7 @@ SelectiveSyncDialog::SelectiveSyncDialog(AccountPtr account, Folder *folder, QWi
, _folder(folder)
, _okButton(nullptr) // defined in init()
{
- bool ok;
+ bool ok = false;
init(account);
QStringList selectiveSyncList = _folder->journalDb()->getSelectiveSyncList(SyncJournalDb::SelectiveSyncBlackList, &ok);
if (ok) {
@@ -463,7 +463,7 @@ void SelectiveSyncDialog::init(const AccountPtr &account)
auto *buttonBox = new QDialogButtonBox(Qt::Horizontal);
_okButton = buttonBox->addButton(QDialogButtonBox::Ok);
connect(_okButton, &QPushButton::clicked, this, &SelectiveSyncDialog::accept);
- QPushButton *button;
+ QPushButton *button = nullptr;
button = buttonBox->addButton(QDialogButtonBox::Cancel);
connect(button, &QAbstractButton::clicked, this, &QDialog::reject);
layout->addWidget(buttonBox);
@@ -472,7 +472,7 @@ void SelectiveSyncDialog::init(const AccountPtr &account)
void SelectiveSyncDialog::accept()
{
if (_folder) {
- bool ok;
+ bool ok = false;
auto oldBlackListSet = _folder->journalDb()->getSelectiveSyncList(SyncJournalDb::SelectiveSyncBlackList, &ok).toSet();
if (!ok) {
return;