Module: kamailio
Branch: 5.0
Commit: 5646626518d670954158e59a5e501f7b5714dea3
URL:
https://github.com/kamailio/kamailio/commit/5646626518d670954158e59a5e501f7…
Author: grumvalski <federico.cabiddu(a)gmail.com>
Committer: Federico Cabiddu <federico.cabiddu(a)gmail.com>
Date: 2017-07-12T10:53:36+02:00
core: return aliases list as an array in core.aliases_list
(cherry picked from commit 13c84b8275f2539e8ca03bec38b79110043d75d2)
---
Modified: src/core/core_cmd.c
---
Diff:
https://github.com/kamailio/kamailio/commit/5646626518d670954158e59a5e501f7…
Patch:
https://github.com/kamailio/kamailio/commit/5646626518d670954158e59a5e501f7…
---
diff --git a/src/core/core_cmd.c b/src/core/core_cmd.c
index fadabf5a7f..b7e4b020bb 100644
--- a/src/core/core_cmd.c
+++ b/src/core/core_cmd.c
@@ -876,14 +876,16 @@ static const char* core_aliases_list_doc[] = {
static void core_aliases_list(rpc_t* rpc, void* c)
{
void *hr;
+ void *hs;
void *ha;
struct host_alias* a;
rpc->add(c, "{", &hr);
rpc->struct_add(hr, "s",
"myself_callbacks",
is_check_self_func_list_set()?"yes":"no");
+ rpc->struct_add(hr, "[", "aliases", &hs);
for(a=aliases; a; a=a->next) {
- rpc->struct_add(hr, "{", "alias", &ha);
+ rpc->struct_add(hs, "{", "alias", &ha);
rpc->struct_add(ha, "sS",
"proto", proto2a(a->proto),
"address", &a->alias