Module: kamailio
Branch: 5.0
Commit: 7859dd239303f6f98f99a2bace8d7a05b49e337c
URL:
https://github.com/kamailio/kamailio/commit/7859dd239303f6f98f99a2bace8d7a0…
Author: grumvalski <federico.cabiddu(a)gmail.com>
Committer: Federico Cabiddu <federico.cabiddu(a)gmail.com>
Date: 2017-07-15T14:51:14+02:00
core: build reply of core.sockets_list as an array
(cherry picked from commit e3ea10ccfcd94af0e7ce6908a1e378b4a9555b93)
---
Modified: src/core/core_cmd.c
---
Diff:
https://github.com/kamailio/kamailio/commit/7859dd239303f6f98f99a2bace8d7a0…
Patch:
https://github.com/kamailio/kamailio/commit/7859dd239303f6f98f99a2bace8d7a0…
---
diff --git a/src/core/core_cmd.c b/src/core/core_cmd.c
index b7e4b020bb..096ac82db9 100644
--- a/src/core/core_cmd.c
+++ b/src/core/core_cmd.c
@@ -920,7 +920,7 @@ static void core_sockets_list(rpc_t* rpc, void* c)
unsigned short proto;
proto=PROTO_UDP;
- rpc->add(c, "{", &hr);
+ rpc->add(c, "[", &hr);
do{
list=get_sock_info_list(proto);
for(si=list?*list:0; si; si=si->next){
@@ -991,7 +991,7 @@ static rpc_export_t core_rpc_methods[] = {
{"core.udp4_raw_info", core_udp4rawinfo, core_udp4rawinfo_doc,
0},
{"core.aliases_list", core_aliases_list, core_aliases_list_doc,
0},
- {"core.sockets_list", core_sockets_list, core_sockets_list_doc,
RET_ARRAY},
+ {"core.sockets_list", core_sockets_list, core_sockets_list_doc,
0},
#ifdef USE_DNS_CACHE
{"dns.mem_info", dns_cache_mem_info, dns_cache_mem_info_doc,
0 },