Module: kamailio Branch: master Commit: 050760411bac006c1e6351f179fab7ea6333b3e5 URL: https://github.com/kamailio/kamailio/commit/050760411bac006c1e6351f179fab7ea...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: 2024-01-22T09:29:31+01:00
lib: presence - remove old commented code and adjust comments
---
Modified: src/lib/presence/notifier_domain.c Modified: src/lib/presence/pidf.c
---
Diff: https://github.com/kamailio/kamailio/commit/050760411bac006c1e6351f179fab7ea... Patch: https://github.com/kamailio/kamailio/commit/050760411bac006c1e6351f179fab7ea...
---
diff --git a/src/lib/presence/notifier_domain.c b/src/lib/presence/notifier_domain.c index 56773d13c1c..8f03828c119 100644 --- a/src/lib/presence/notifier_domain.c +++ b/src/lib/presence/notifier_domain.c @@ -223,33 +223,6 @@ static void free_subscription(qsa_subscription_t *s) cds_free(s); }
-/*static void add_server_subscription(notifier_t *n, qsa_subscription_t *s) -{ - server_subscription_t server_s; - - server_s.notifier_data = NULL; - if (n->subscribe(n, &s->record_id, s, &server_s.notifier_data) == 0) { - server_s.notifier = n; - vector_add(&s->server_subscriptions, &server_s); - } - else ERROR_LOG("subscription not accepted by notifier %p\n", n); -} - -static void remove_notifier_from_subscription(qsa_subscription_t *s, notifier_t *n) -{ - int cnt,i; - - cnt = vector_size(&s->server_subscriptions); - for (i = 0; i < cnt; i++) { - ss = vector_get_ptr(&s->server_subscriptions, i); - if (!ss) continue; - / * FIXME: call n->unsubscribe ??? - * NO this is called from unregister which is initiated - * by the notifier (may be synchronized there!) * / - if (ss->notifier == n) ss->notifier = NULL; / * "zombie" * / - } -} -*/
/* -------- Domain initialization/destruction functions -------- */
diff --git a/src/lib/presence/pidf.c b/src/lib/presence/pidf.c index d875ce974c4..3f00314a5fa 100644 --- a/src/lib/presence/pidf.c +++ b/src/lib/presence/pidf.c @@ -170,9 +170,9 @@ static void doc_add_presentity(
DEBUG_LOG("doc_add_presentity()\n"); if(use_cpim_pidf_ns) - dstr_append_zt( - buf, "<presence xmlns="urn:ietf:params:xml:ns:cpim-pidf" " - "entity=""); + dstr_append_zt(buf, + "<presence xmlns="urn:ietf:params:xml:ns:cpim-pidf" " + "entity=""); else dstr_append_zt(buf, "<presence xmlns="urn:ietf:params:xml:ns:pidf" entity=""); @@ -402,7 +402,7 @@ static int read_tuple(xmlNode *tuple, presence_tuple_info_t **dst, status = presence_tuple_open; if(strcasecmp(s, "closed") == 0) status = presence_tuple_closed; - /* FIXME: handle not standardized variants too (add note to basic status) */ + /* NOTE: handle not standardized variants too (add note to basic status) */
/* get ID from tuple node attribute? */ id.s = (char *)get_attr_value(find_attr(tuple->properties, "id")); @@ -433,7 +433,7 @@ static int read_tuple(xmlNode *tuple, presence_tuple_info_t **dst, } else if(cmp_node(n, "status", ns) >= 0) { /* skip, already processed */ } else if(cmp_node(n, "timestamp", ns) >= 0) { - /* FIXME: process */ + /* TODO: process */ } else { /* PIDF extensions - only from non-PIDF namespace? */ res = read_extension(n, &ex, doc); if((res == 0) && ex)