mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-07-22 22:21:09 -04:00
fixed uninitialized pointer in MainWindow
This commit is contained in:
parent
19f1a645f8
commit
6179d22ad5
1 changed files with 20 additions and 13 deletions
|
@ -247,15 +247,22 @@ MainWindow::MainWindow(QWidget* parent, Qt::WindowFlags flags)
|
||||||
|
|
||||||
if(hiddenmode)
|
if(hiddenmode)
|
||||||
{
|
{
|
||||||
|
#ifdef RETROTOR
|
||||||
torstatus = new TorStatus();
|
torstatus = new TorStatus();
|
||||||
torstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowTor", QVariant(true)).toBool());
|
torstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowTor", QVariant(true)).toBool());
|
||||||
statusBar()->addWidget(torstatus);
|
statusBar()->addWidget(torstatus);
|
||||||
torstatus->getTorStatus();
|
torstatus->getTorStatus();
|
||||||
|
#else
|
||||||
|
torstatus = NULL ;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
natstatus = NULL ;
|
||||||
|
dhtstatus = NULL ;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
torstatus = NULL ;
|
torstatus = NULL ;
|
||||||
|
|
||||||
#ifndef RETROTOR
|
|
||||||
natstatus = new NATStatus();
|
natstatus = new NATStatus();
|
||||||
if(hiddenmode) natstatus->setVisible(false);
|
if(hiddenmode) natstatus->setVisible(false);
|
||||||
else natstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowNAT", QVariant(true)).toBool());
|
else natstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowNAT", QVariant(true)).toBool());
|
||||||
|
@ -267,7 +274,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WindowFlags flags)
|
||||||
else dhtstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowDHT", QVariant(true)).toBool());
|
else dhtstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowDHT", QVariant(true)).toBool());
|
||||||
statusBar()->addWidget(dhtstatus);
|
statusBar()->addWidget(dhtstatus);
|
||||||
dhtstatus->getDHTStatus();
|
dhtstatus->getDHTStatus();
|
||||||
#endif
|
}
|
||||||
|
|
||||||
hashingstatus = new HashingStatus();
|
hashingstatus = new HashingStatus();
|
||||||
hashingstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowHashing", QVariant(true)).toBool());
|
hashingstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowHashing", QVariant(true)).toBool());
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue