Main: fix crash if no database was configured

Add nullptr check, and return early from glue_db_init_and_load().
This commit is contained in:
Max Kellermann 2013-09-26 17:33:46 +02:00
parent a2c4037a24
commit 7ca0aedcfc

View File

@ -181,6 +181,9 @@ glue_db_init_and_load(void)
param = allocated;
}
if (param == nullptr)
return true;
Error error;
if (!DatabaseGlobalInit(*param, error))
FatalError(error);