Skip to content
Snippets Groups Projects
Commit 1c9495df authored by Sébastien Blin's avatar Sébastien Blin Committed by Philippe Gorley
Browse files

ringmainwindow: protect setTopAccount from null pointer exceptions


Change-Id: I2bc157c1656d9d4524bea8d8694909437da5cfb7
Reviewed-by: default avatarPhilippe Gorley <philippe.gorley@savoirfairelinux.com>
parent 83dd8bb8
No related branches found
No related tags found
No related merge requests found
......@@ -426,7 +426,9 @@ on_account_changed(RingMainWindow* self)
priv->cpp->enterAccountCreationWizard(true);
} else {
priv->cpp->leaveAccountCreationWizard();
priv->cpp->accountInfo_->accountModel->setTopAccount(accountId);
if (priv->cpp->accountInfo_) {
priv->cpp->accountInfo_->accountModel->setTopAccount(accountId);
}
priv->cpp->onAccountSelectionChange(accountId);
gtk_notebook_set_show_tabs(GTK_NOTEBOOK(priv->notebook_contacts),
priv->cpp->accountInfo_->contactModel->hasPendingRequests());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment