From 3662a36092269e0a28a4ce1244d9f615980d489c Mon Sep 17 00:00:00 2001 From: Gio Date: Thu, 15 Dec 2016 11:20:13 +0100 Subject: [PATCH] Coherent behaviour of general config with auto-login compile option --- retroshare-gui/src/gui/settings/GeneralPage.cpp | 11 +++++++++-- retroshare.pri | 2 +- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/retroshare-gui/src/gui/settings/GeneralPage.cpp b/retroshare-gui/src/gui/settings/GeneralPage.cpp index 63d1910a8..7aa5f016f 100755 --- a/retroshare-gui/src/gui/settings/GeneralPage.cpp +++ b/retroshare-gui/src/gui/settings/GeneralPage.cpp @@ -32,8 +32,8 @@ #include /** Constructor */ -GeneralPage::GeneralPage(QWidget * parent, Qt::WindowFlags flags) -: ConfigPage(parent, flags) +GeneralPage::GeneralPage(QWidget * parent, Qt::WindowFlags flags) : + ConfigPage(parent, flags) { /* Invoke the Qt Designer generated object setup routine */ ui.setupUi(this); @@ -75,6 +75,13 @@ GeneralPage::GeneralPage(QWidget * parent, Qt::WindowFlags flags) #endif } ui.useLocalServer->setEnabled(true); + +#ifdef RS_AUTOLOGIN + ui.autoLogin->setToolTip(tr("For security reasons the usage of auto-login is discouraged, you can enable it but you are on your own!")); +#else // RS_AUTOLOGIN + ui.autoLogin->setEnabled(false); + ui.autoLogin->setToolTip(tr("Your RetroShare build has auto-login disabled.")); +#endif // RS_AUTOLOGIN } /** Destructor */ diff --git a/retroshare.pri b/retroshare.pri index 8410ba442..3160abcae 100644 --- a/retroshare.pri +++ b/retroshare.pri @@ -151,5 +151,5 @@ sqlcipher:DEFINES -= NO_SQLCIPHER no_sqlcipher:DEFINES *= NO_SQLCIPHER rs_autologin { DEFINES *= RS_AUTOLOGIN - warning(You have enabled RetroShare auto-login, this is discouraged. The usage of auto-login on some linux distributions may allow someone having access to your session to steal the SSL keys of your node location and therefore compromise your security) + warning("You have enabled RetroShare auto-login, this is discouraged. The usage of auto-login on some linux distributions may allow someone having access to your session to steal the SSL keys of your node location and therefore compromise your security") }