From 7fca3be419ac2160a5b5e193e331ee2d56d48dc2 Mon Sep 17 00:00:00 2001 From: Jehan Monnier Date: Fri, 5 Feb 2016 17:10:38 +0100 Subject: [PATCH] On invalidate, only notify friend with an already known presence model --- coreapi/friend.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/coreapi/friend.c b/coreapi/friend.c index 0ba8af361..c5e515e20 100644 --- a/coreapi/friend.c +++ b/coreapi/friend.c @@ -252,9 +252,9 @@ void linphone_friend_invalidate_subscription(LinphoneFriend *lf){ /* Notify application that we no longer know the presence activity */ if (lf->presence != NULL) { linphone_presence_model_unref(lf->presence); + lf->presence = linphone_presence_model_new_with_activity(LinphonePresenceActivityOffline,"unknown activity"); + linphone_core_notify_notify_presence_received(lc,lf); } - lf->presence = linphone_presence_model_new_with_activity(LinphonePresenceActivityOffline,"unknown activity"); - linphone_core_notify_notify_presence_received(lc,lf); lf->initial_subscribes_sent=FALSE; }