X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fcore%2Fcore.cpp;h=d613e8f8bf4affa454a51127277b9ae4ef89e3ba;hp=889d15af8c1d02af6180370d4c4eb03597ab4d9b;hb=32582b14a442c35d1a64131ac10792683fb06f82;hpb=05249bc1337473abcb3076be9f20c82e14211d5a diff --git a/src/core/core.cpp b/src/core/core.cpp index 889d15af..d613e8f8 100644 --- a/src/core/core.cpp +++ b/src/core/core.cpp @@ -403,10 +403,15 @@ bool Core::initStorage(const QString &backend, const QVariantMap &settings, bool return false; // trigger setup process if (storage->setup(settings)) return initStorage(backend, settings, false); + return false; + // if initialization wasn't successful, we quit to keep from coming up unconfigured case Storage::NotAvailable: qCritical() << "FATAL: Selected storage backend is not available:" << backend; - exit(EXIT_FAILURE); + if (!setup) + exit(EXIT_FAILURE); + return false; + case Storage::IsReady: // delete all other backends _registeredStorageBackends.clear(); @@ -495,10 +500,15 @@ bool Core::initAuthenticator(const QString &backend, const QVariantMap &settings return false; // trigger setup process if (auth->setup(settings)) return initAuthenticator(backend, settings, false); + return false; + // if initialization wasn't successful, we quit to keep from coming up unconfigured case Authenticator::NotAvailable: qCritical() << "FATAL: Selected auth backend is not available:" << backend; - exit(EXIT_FAILURE); + if (!setup) + exit(EXIT_FAILURE); + return false; + case Authenticator::IsReady: // delete all other backends _registeredAuthenticators.clear();