From: Anthony Minessale Date: Mon, 20 Dec 2010 20:36:03 +0000 (-0600) Subject: more presence and not the kind with bows and ribbons X-Git-Tag: v1.2-rc1~223^2~9^2~1^2~8 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cfd6876c2127bd64b7c2ced80407b5b9f962549b;p=thirdparty%2Ffreeswitch.git more presence and not the kind with bows and ribbons --- diff --git a/src/mod/endpoints/mod_sofia/sofia_presence.c b/src/mod/endpoints/mod_sofia/sofia_presence.c index f0cade3e61..059018986c 100644 --- a/src/mod/endpoints/mod_sofia/sofia_presence.c +++ b/src/mod/endpoints/mod_sofia/sofia_presence.c @@ -840,10 +840,11 @@ static void actual_sofia_presence_event_handler(switch_event_t *event) "where sip_subscriptions.expires > -1 and " "(event='%q' or event='%q') and sub_to_user='%q' " "and (sub_to_host='%q' or presence_hosts like '%%%q%%') " - "and (sip_subscriptions.profile_name = '%q' or sip_subscriptions.presence_hosts != sip_subscriptions.sub_to_host)", + "and (sip_subscriptions.profile_name = '%q' or sip_subscriptions.presence_hosts != sip_subscriptions.sub_to_host) " + "and (presence_id is null or presence_id = '%q@%q')", switch_str_nil(status), switch_str_nil(rpid), host, dh.status,dh.rpid, - event_type, alt_event_type, euser, host, host, profile->name))) { + event_type, alt_event_type, euser, host, host, profile->name, euser, host))) { struct presence_helper helper = { 0 };