[sr-dev] [kamailio/kamailio] keepalive: added add/del/get/flush rpc commands (#2177)

Olle E. Johansson notifications at github.com
Thu Jan 2 16:17:34 CET 2020


oej commented on this pull request.



> +	return;
+}
+static const char *keepalive_rpc_get_doc[2] = {
+		"gets destination info data  from keepalive memory. usage keepalive.get sip:xx at domain listname", 0};
+
+
+static void keepalive_rpc_flush(rpc_t *rpc, void *ctx)
+{
+	ka_dest_t *dest;
+	LM_DBG("Keepalive flushes  \n");
+	ka_lock_destination_list();
+
+	for(dest = ka_destinations_list->first; dest != NULL; dest = dest->next) {
+		free_destination(dest);
+	}
+	ka_destinations_list->first = 0;

Are you sure you want to set it to "0" here? first seems to be of type ka_dest_t * so maybe NULL is better?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2177#pullrequestreview-337704094
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20200102/716cd9e3/attachment.html>


More information about the sr-dev mailing list