Folks: better check for NULL persona
While it is likely that there is a GError when adding a persona fails, better check for it explicitly. The code would crash with a NULL persona pointer.
This commit is contained in:
parent
37ed37fd08
commit
437abf1606
1 changed files with 1 additions and 1 deletions
|
@ -874,7 +874,7 @@ void IndividualAggregator::addContactDone(const GError *gerror,
|
|||
{
|
||||
try {
|
||||
// Handle result of folks_persona_store_add_persona_from_details().
|
||||
if (!gerror) {
|
||||
if (!persona || gerror) {
|
||||
GErrorCXX::throwError("add contact", gerror);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue