kamailio.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
List overview
Download
sr-dev
November 2024
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
sr-dev@lists.kamailio.org
20 participants
367 discussions
Start a n
N
ew thread
git:master:c82aa6e9: core: helper functions to convert ip to string using a pool of buffers
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: c82aa6e92d3475bb56db761ba65abb64e8f712fd URL:
https://github.com/kamailio/kamailio/commit/c82aa6e92d3475bb56db761ba65abb6…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2024-11-25T10:16:07+01:00 core: helper functions to convert ip to string using a pool of buffers --- Modified: src/core/ip_addr.c Modified: src/core/ip_addr.h --- Diff:
https://github.com/kamailio/kamailio/commit/c82aa6e92d3475bb56db761ba65abb6…
Patch:
https://github.com/kamailio/kamailio/commit/c82aa6e92d3475bb56db761ba65abb6…
--- diff --git a/src/core/ip_addr.c b/src/core/ip_addr.c index 02c26f969d5..8e2ae6cf42d 100644 --- a/src/core/ip_addr.c +++ b/src/core/ip_addr.c @@ -298,6 +298,52 @@ char *ip_addr2strz(struct ip_addr *ip) return buff; } +#define IP_ADDR_BUF_NR 8 +static char _ksr_addr2x_buff[IP_ADDR_BUF_NR][IP_ADDR_MAX_STR_SIZE]; +static int _ksr_addr2x_idx = 0; + +/* fast ip_addr -> string converter; + * it uses an internal buffer + */ +char *ip_addr2xa(struct ip_addr *ip) +{ + int len; + char *buff; + + buff = _ksr_addr2x_buff[_ksr_addr2x_idx]; + _ksr_addr2x_idx = (_ksr_addr2x_idx + 1) % IP_ADDR_BUF_NR; + + len = ip_addr2sbuf(ip, buff, sizeof(buff) - 1); + buff[len] = 0; + + return buff; +} + + +/* full address in text representation, including [] for ipv6 */ +char *ip_addr2xstrz(struct ip_addr *ip) +{ + char *p; + int len; + char *buff; + + buff = _ksr_addr2x_buff[_ksr_addr2x_idx]; + _ksr_addr2x_idx = (_ksr_addr2x_idx + 1) % IP_ADDR_BUF_NR; + + p = buff; + if(ip->af == AF_INET6) { + *p++ = '['; + } + len = ip_addr2sbuf(ip, p, sizeof(buff) - 3); + p += len; + if(ip->af == AF_INET6) { + *p++ = ']'; + } + *p = 0; + + return buff; +} + /* returns an asciiz string containing the ip and the port * (<ip_addr>:port or [<ipv6_addr>]:port) diff --git a/src/core/ip_addr.h b/src/core/ip_addr.h index 4a266391190..b55c78bd8bc 100644 --- a/src/core/ip_addr.h +++ b/src/core/ip_addr.h @@ -614,14 +614,18 @@ int ip_addr2sbufz(struct ip_addr *ip, char *buff, int len); #define IP_ADDR_MAX_STR_SIZE (IP6_MAX_STR_SIZE + 1) /* ip62ascii + \0*/ #define IP_ADDR_MAX_STRZ_SIZE (IP6_MAX_STR_SIZE + 3) /* ip62ascii + [ + ] + \0*/ -/* fast ip_addr -> string converter; - * it uses an internal buffer - */ +/* ip addr to string converter; it uses an internal static buffer */ char *ip_addr2a(struct ip_addr *ip); +/* ip addr to string converter; it uses a pool of internal static buffers */ +char *ip_addr2xa(struct ip_addr *ip); -/* full address in text representation, including [] for ipv6 */ +/* full address in text representation, including [] for ipv6 + * - it uses an internal static buffer */ char *ip_addr2strz(struct ip_addr *ip); +/* full address in text representation, including [] for ipv6 + * - it uses a pool of internal static buffers */ +char *ip_addr2xstrz(struct ip_addr *ip); #define SU2A_MAX_STR_SIZE \
4 weeks, 1 day
1
0
0
0
git:master:8d12a04b: async: fixed name of pv in log message
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 8d12a04b57db2f3da6f522b6685161b38ff40d5e URL:
https://github.com/kamailio/kamailio/commit/8d12a04b57db2f3da6f522b6685161b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2024-11-25T09:16:30+01:00 async: fixed name of pv in log message --- Modified: src/modules/async/async_sleep.c --- Diff:
https://github.com/kamailio/kamailio/commit/8d12a04b57db2f3da6f522b6685161b…
Patch:
https://github.com/kamailio/kamailio/commit/8d12a04b57db2f3da6f522b6685161b…
--- diff --git a/src/modules/async/async_sleep.c b/src/modules/async/async_sleep.c index 5fb8861a861..26d2e067597 100644 --- a/src/modules/async/async_sleep.c +++ b/src/modules/async/async_sleep.c @@ -701,7 +701,7 @@ int pv_parse_async_name(pv_spec_t *sp, str *in) return 0; error: - LM_ERR("unknown PV time name %.*s\n", in->len, in->s); + LM_ERR("unknown PV async name %.*s\n", in->len, in->s); return -1; }
4 weeks, 1 day
1
0
0
0
git:master:bebf3782: corex: fixed name of pv in log message
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: bebf378252484f770f2dbc9a27e6ad2b7ff7f880 URL:
https://github.com/kamailio/kamailio/commit/bebf378252484f770f2dbc9a27e6ad2…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2024-11-25T09:16:30+01:00 corex: fixed name of pv in log message --- Modified: src/modules/corex/corex_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/bebf378252484f770f2dbc9a27e6ad2…
Patch:
https://github.com/kamailio/kamailio/commit/bebf378252484f770f2dbc9a27e6ad2…
--- diff --git a/src/modules/corex/corex_mod.c b/src/modules/corex/corex_mod.c index c5008bfb445..115e50f8a03 100644 --- a/src/modules/corex/corex_mod.c +++ b/src/modules/corex/corex_mod.c @@ -1533,7 +1533,7 @@ static int pv_parse_atkv_name(pv_spec_t *sp, str *in) return 0; error: - LM_ERR("unknown PV time name %.*s\n", in->len, in->s); + LM_ERR("unknown PV atkv name %.*s\n", in->len, in->s); return -1; }
4 weeks, 1 day
1
0
0
0
git:master:619b1f80: log_custom: add fixup_free* to exported functions
by Federico Cabiddu
Module: kamailio Branch: master Commit: 619b1f80d648e5869389b431e17c12f7b730634e URL:
https://github.com/kamailio/kamailio/commit/619b1f80d648e5869389b431e17c12f…
Author: Federico Cabiddu <federico.cabiddu(a)gmail.com> Committer: Federico Cabiddu <federico.cabiddu(a)gmail.com> Date: 2024-11-25T08:34:48+01:00 log_custom: add fixup_free* to exported functions --- Modified: src/modules/log_custom/log_custom_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/619b1f80d648e5869389b431e17c12f…
Patch:
https://github.com/kamailio/kamailio/commit/619b1f80d648e5869389b431e17c12f…
--- diff --git a/src/modules/log_custom/log_custom_mod.c b/src/modules/log_custom/log_custom_mod.c index f7ae9a228c5..abb3ababd3b 100644 --- a/src/modules/log_custom/log_custom_mod.c +++ b/src/modules/log_custom/log_custom_mod.c @@ -47,25 +47,28 @@ static int w_log_udp(struct sip_msg *msg, char *txt, char *p2); void _lc_core_log_udp(int lpriority, const char *format, ...); +/* clang-format off */ static cmd_export_t cmds[] = { - {"log_udp", (cmd_function)w_log_udp, 1, fixup_spve_null, 0, ANY_ROUTE}, - {0, 0, 0, 0, 0, 0}}; + {"log_udp", (cmd_function)w_log_udp, 1, fixup_spve_null, fixup_free_spve_null, ANY_ROUTE}, + {0, 0, 0, 0, 0, 0} +}; static param_export_t params[] = {{0, 0, 0}}; struct module_exports exports = { - "log_custom", /* module name */ - DEFAULT_DLFLAGS, /* dlopen flags */ - cmds, /* exported functions */ - params, /* exported parameters */ - 0, /* exported RPC functions */ - 0, /* exported pseudo-variables */ - 0, /* response function */ - mod_init, /* module initialization function */ - child_init, /* per child init function */ - mod_destroy /* destroy function */ + "log_custom", /* module name */ + DEFAULT_DLFLAGS, /* dlopen flags */ + cmds, /* exported functions */ + params, /* exported parameters */ + 0, /* exported RPC functions */ + 0, /* exported pseudo-variables */ + 0, /* response function */ + mod_init, /* module initialization function */ + child_init, /* per child init function */ + mod_destroy /* destroy function */ }; +/* clang-format on */ /** * init module function */
4 weeks, 1 day
1
0
0
0
git:master:adffa9e2: ldap: add fixup_free* to exported functions
by Federico Cabiddu
Module: kamailio Branch: master Commit: adffa9e2b31bf0ad7070420ac821a914fc2bcd6b URL:
https://github.com/kamailio/kamailio/commit/adffa9e2b31bf0ad7070420ac821a91…
Author: Federico Cabiddu <federico.cabiddu(a)gmail.com> Committer: Federico Cabiddu <federico.cabiddu(a)gmail.com> Date: 2024-11-25T08:32:48+01:00 ldap: add fixup_free* to exported functions --- Modified: src/modules/ldap/ldap_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/adffa9e2b31bf0ad7070420ac821a91…
Patch:
https://github.com/kamailio/kamailio/commit/adffa9e2b31bf0ad7070420ac821a91…
--- diff --git a/src/modules/ldap/ldap_mod.c b/src/modules/ldap/ldap_mod.c index 27d44b9d88b..8303885f6ba 100644 --- a/src/modules/ldap/ldap_mod.c +++ b/src/modules/ldap/ldap_mod.c @@ -59,6 +59,8 @@ static int child_init(int rank); static int ldap_result_fixup(void **param, int param_no); static int ldap_filter_url_encode_fixup(void **param, int param_no); static int ldap_result_check_fixup(void **param, int param_no); +static int ldap_fixup_free(void **param, int param_no); +static int ldap_filter_url_encode_fixup_free(void **param, int param_no); /* * exported functions @@ -94,25 +96,25 @@ static dictionary *config_vals = NULL; /* clang-format off */ static cmd_export_t cmds[] = { {"ldap_search", (cmd_function)w_ldap_search, 1, - fixup_spve_null, 0, + fixup_spve_null, fixup_free_spve_null, REQUEST_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|ONREPLY_ROUTE|LOCAL_ROUTE}, {"ldap_result", (cmd_function)w_ldap_result1, 1, - ldap_result_fixup, 0, + ldap_result_fixup, ldap_fixup_free, REQUEST_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|ONREPLY_ROUTE|LOCAL_ROUTE}, {"ldap_result", (cmd_function)w_ldap_result2, 2, - ldap_result_fixup, 0, + ldap_result_fixup, ldap_fixup_free, REQUEST_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|ONREPLY_ROUTE|LOCAL_ROUTE}, {"ldap_result_next", (cmd_function)w_ldap_result_next, 0, 0, 0, REQUEST_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|ONREPLY_ROUTE|LOCAL_ROUTE}, {"ldap_result_check", (cmd_function)w_ldap_result_check_1, 1, - ldap_result_check_fixup, 0, + ldap_result_check_fixup, ldap_fixup_free, REQUEST_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|ONREPLY_ROUTE|LOCAL_ROUTE}, {"ldap_result_check", (cmd_function)w_ldap_result_check_2, 2, - ldap_result_check_fixup, 0, + ldap_result_check_fixup, ldap_fixup_free, REQUEST_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|ONREPLY_ROUTE|LOCAL_ROUTE}, {"ldap_filter_url_encode", (cmd_function)w_ldap_filter_url_encode, 2, - ldap_filter_url_encode_fixup, 0, + ldap_filter_url_encode_fixup, ldap_filter_url_encode_fixup_free, REQUEST_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|ONREPLY_ROUTE|LOCAL_ROUTE}, {"load_ldap", (cmd_function)load_ldap, 0, 0, 0, 0}, @@ -374,6 +376,14 @@ static int ldap_result_fixup(void **param, int param_no) return 0; } +static int ldap_fixup_free(void **param, int param_no) +{ + if(param_no == 1) { + pkg_free(*param); + } + return 0; +} + static int ldap_result_check_fixup(void **param, int param_no) { struct ldap_result_check_params *lp; @@ -475,6 +485,14 @@ static int ldap_filter_url_encode_fixup(void **param, int param_no) return 0; } +static int ldap_filter_url_encode_fixup_free(void **param, int param_no) +{ + if(param_no == 2) { + pkg_free(*param); + } + return 0; +} + /** * */
4 weeks, 1 day
1
0
0
0
git:master:cdafda78: pkg/kamailio: added support for CentOS 10 [skip-ci]
by Sergey Safarov
Module: kamailio Branch: master Commit: cdafda78c9fc98d9d9fdb7f94e77c9bc60ebf4d1 URL:
https://github.com/kamailio/kamailio/commit/cdafda78c9fc98d9d9fdb7f94e77c9b…
Author: Sergey Safarov <s.safarov(a)anycast-lb.net> Committer: Sergey Safarov <s.safarov(a)anycast-lb.net> Date: 2024-11-23T22:03:17+02:00 pkg/kamailio: added support for CentOS 10 [skip-ci] --- Modified: pkg/kamailio/obs/kamailio.spec --- Diff:
https://github.com/kamailio/kamailio/commit/cdafda78c9fc98d9d9fdb7f94e77c9b…
Patch:
https://github.com/kamailio/kamailio/commit/cdafda78c9fc98d9d9fdb7f94e77c9b…
--- diff --git a/pkg/kamailio/obs/kamailio.spec b/pkg/kamailio/obs/kamailio.spec index 04eb6ba9076..9c32a293be2 100644 --- a/pkg/kamailio/obs/kamailio.spec +++ b/pkg/kamailio/obs/kamailio.spec @@ -113,21 +113,21 @@ %bcond_without wolfssl %endif -%if 0%{?rhel} == 9 +%if 0%{?rhel} == 9 || 0%{?rhel} == 10 %if 0%{?centos_ver} %define dist_name centos %define dist_version %{?centos} -%define dist .el9.centos +%define dist .el%{?centos_ver}.centos %endif %if 0%{?almalinux_ver} %define dist_name centos %define dist_version %{?almalinux} -%define dist .el9.almalinux +%define dist .el%{?almalinux_ver}.almalinux %endif %if 0%{?rocky_ver} %define dist_name centos %define dist_version %{?rocky} -%define dist .el9.rocky +%define dist .el%{?rocky_ver}.rocky %endif %if 0%{?centos_ver} == 0 && 0%{?almalinux_ver} == 0 && 0%{?rocky_ver} == 0 %define dist_name rhel
1 month
1
0
0
0
git:master:b1f9fc1d: corex: added $atkv(name) variable
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: b1f9fc1d586975a12f6a6d56a76dbf2d3541124c URL:
https://github.com/kamailio/kamailio/commit/b1f9fc1d586975a12f6a6d56a76dbf2…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2024-11-22T19:30:25+01:00 corex: added $atkv(name) variable - get async type-key-value attributes --- Modified: src/modules/corex/corex_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/b1f9fc1d586975a12f6a6d56a76dbf2…
Patch:
https://github.com/kamailio/kamailio/commit/b1f9fc1d586975a12f6a6d56a76dbf2…
--- diff --git a/src/modules/corex/corex_mod.c b/src/modules/corex/corex_mod.c index 0fdf35060ea..c5008bfb445 100644 --- a/src/modules/corex/corex_mod.c +++ b/src/modules/corex/corex_mod.c @@ -38,6 +38,7 @@ #include "../../core/forward.h" #include "../../core/dns_cache.h" #include "../../core/data_lump.h" +#include "../../core/async_task.h" #include "../../core/parser/parse_uri.h" #include "../../core/parser/parse_param.h" @@ -101,12 +102,17 @@ static int corex_dns_cache_param_add(str *pval); static int corex_sip_reply_out(sr_event_param_t *evp); +static int pv_get_atkv(sip_msg_t *msg, pv_param_t *param, pv_value_t *res); +static int pv_parse_atkv_name(pv_spec_t *sp, str *in); + /* clang-format off */ static pv_export_t mod_pvs[] = { {{"cfg", (sizeof("cfg") - 1)}, PVT_OTHER, pv_get_cfg, 0, pv_parse_cfg_name, 0, 0, 0}, {{"lsock", (sizeof("lsock") - 1)}, PVT_OTHER, pv_get_lsock, 0, pv_parse_lsock_name, 0, 0, 0}, + {{"atkv", (sizeof("atkv") - 1)}, PVT_OTHER, pv_get_atkv, 0, + pv_parse_atkv_name, 0, 0, 0}, {{0, 0}, 0, 0, 0, 0, 0, 0, 0} }; @@ -1456,6 +1462,81 @@ static int corex_sip_reply_out(sr_event_param_t *evp) return 0; } +/** + * + */ +static int pv_get_atkv(sip_msg_t *msg, pv_param_t *param, pv_value_t *res) +{ + async_tkv_param_t *atkvp = NULL; + async_wgroup_t *awg = NULL; + + atkvp = ksr_async_tkv_param_get(); + + if(atkvp == NULL) { + return pv_get_null(msg, param, res); + } + + switch(param->pvn.u.isname.name.n) { + case 0: + return pv_get_sintval(msg, param, res, (long)atkvp->dtype); + case 1: + if(atkvp->skey.s == NULL || atkvp->skey.len < 0) { + return pv_get_null(msg, param, res); + } + return pv_get_strval(msg, param, res, &atkvp->skey); + case 2: + if(atkvp->sval.s == NULL || atkvp->sval.len < 0) { + return pv_get_null(msg, param, res); + } + return pv_get_strval(msg, param, res, &atkvp->sval); + case 3: + awg = async_task_workers_get_crt(); + if(awg == NULL || awg->name.s == NULL || awg->name.len < 0) { + return pv_get_null(msg, param, res); + } + return pv_get_strval(msg, param, res, &awg->name); + default: + return pv_get_null(msg, param, res); + } +} + +/** + * + */ +static int pv_parse_atkv_name(pv_spec_t *sp, str *in) +{ + if(sp == NULL || in == NULL || in->len <= 0) + return -1; + + switch(in->len) { + case 3: + if(strncmp(in->s, "key", 3) == 0) { + sp->pvp.pvn.u.isname.name.n = 1; + } else if(strncmp(in->s, "val", 3) == 0) { + sp->pvp.pvn.u.isname.name.n = 2; + } + break; + case 4: + if(strncmp(in->s, "type", 4) == 0) + sp->pvp.pvn.u.isname.name.n = 0; + break; + case 5: + if(strncmp(in->s, "gname", 5) == 0) + sp->pvp.pvn.u.isname.name.n = 3; + break; + default: + goto error; + } + sp->pvp.pvn.type = PV_NAME_INTSTR; + sp->pvp.pvn.u.isname.type = 0; + + return 0; + +error: + LM_ERR("unknown PV time name %.*s\n", in->len, in->s); + return -1; +} + /** *
1 month
1
0
0
0
git:master:88ca83a5: core: function to get current tkv param
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 88ca83a5379dbaca3a87fdcb26dd2855b5ba871d URL:
https://github.com/kamailio/kamailio/commit/88ca83a5379dbaca3a87fdcb26dd285…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2024-11-22T19:24:18+01:00 core: function to get current tkv param --- Modified: src/core/async_task.c Modified: src/core/async_task.h --- Diff:
https://github.com/kamailio/kamailio/commit/88ca83a5379dbaca3a87fdcb26dd285…
Patch:
https://github.com/kamailio/kamailio/commit/88ca83a5379dbaca3a87fdcb26dd285…
--- diff --git a/src/core/async_task.c b/src/core/async_task.c index 17c385a51fd..e66205335fa 100644 --- a/src/core/async_task.c +++ b/src/core/async_task.c @@ -538,6 +538,14 @@ static async_wgroup_t *_async_tkv_awg = NULL; static async_tkv_param_t *_ksr_async_tkv_param = NULL; static int _ksr_async_tkv_ridx = -1; +/** + * + */ +async_tkv_param_t *ksr_async_tkv_param_get(void) +{ + return _ksr_async_tkv_param; +} + /** * */ diff --git a/src/core/async_task.h b/src/core/async_task.h index b4276c2d27c..67df94d6169 100644 --- a/src/core/async_task.h +++ b/src/core/async_task.h @@ -65,8 +65,9 @@ typedef struct async_tkv_param str sval; } async_tkv_param_t; -#define KSR_ASYNC_TKV_SIZE 512 +#define KSR_ASYNC_TKV_SIZE 1024 void async_tkv_init(void); int async_tkv_emit(int dtype, char *pkey, char *fmt, ...); +async_tkv_param_t *ksr_async_tkv_param_get(void); #endif
1 month
1
0
0
0
git:master:d2c98b63: core: main - init async type-key-value framework
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: d2c98b63d141a88f29a379f6b5f23122d4997e82 URL:
https://github.com/kamailio/kamailio/commit/d2c98b63d141a88f29a379f6b5f2312…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2024-11-22T19:17:44+01:00 core: main - init async type-key-value framework --- Modified: src/main.c --- Diff:
https://github.com/kamailio/kamailio/commit/d2c98b63d141a88f29a379f6b5f2312…
Patch:
https://github.com/kamailio/kamailio/commit/d2c98b63d141a88f29a379f6b5f2312…
--- diff --git a/src/main.c b/src/main.c index 6aacc523db8..870a334559b 100644 --- a/src/main.c +++ b/src/main.c @@ -3333,6 +3333,7 @@ int main(int argc, char **argv) #endif /* USE_TLS */ #endif /* USE_TCP */ + async_tkv_init(); sr_core_ert_run_xname("core:modinit-before"); if(init_modules() != 0) {
1 month
1
0
0
0
git:master:f4e04dac: pv: add fixup_free* to exported functions
by Victor Seva
Module: kamailio Branch: master Commit: f4e04dac07bc11da08288a8a4a4957c5799c37e9 URL:
https://github.com/kamailio/kamailio/commit/f4e04dac07bc11da08288a8a4a4957c…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-11-22T15:48:18+01:00 pv: add fixup_free* to exported functions --- Modified: src/modules/pv/pv.c --- Diff:
https://github.com/kamailio/kamailio/commit/f4e04dac07bc11da08288a8a4a4957c…
Patch:
https://github.com/kamailio/kamailio/commit/f4e04dac07bc11da08288a8a4a4957c…
--- diff --git a/src/modules/pv/pv.c b/src/modules/pv/pv.c index 3feedf66cda..e014cf37449 100644 --- a/src/modules/pv/pv.c +++ b/src/modules/pv/pv.c @@ -535,9 +535,9 @@ int pv_register_api(pv_api_t *); /* clang-format off */ static cmd_export_t cmds[] = { {"pv_isset", (cmd_function)pv_isset, 1, - fixup_pvar_null, 0, ANY_ROUTE}, + fixup_pvar_null, fixup_free_pvar_null, ANY_ROUTE}, {"pv_unset", (cmd_function)pv_unset, 1, - fixup_pvar_null, 0, ANY_ROUTE}, + fixup_pvar_null, fixup_free_pvar_null, ANY_ROUTE}, {"pv_xavp_print", (cmd_function)pv_xavp_print, 0, 0, 0, ANY_ROUTE}, {"pv_xavu_print", (cmd_function)pv_xavu_print, 0, 0, 0, ANY_ROUTE}, {"pv_xavi_print", (cmd_function)pv_xavi_print, 0, 0, 0, ANY_ROUTE}, @@ -552,9 +552,9 @@ static cmd_export_t cmds[] = { {"not_empty", (cmd_function)pv_not_empty, 1, fixup_pvar_null, fixup_free_pvar_null, ANY_ROUTE}, {"xavp_copy", (cmd_function)w_xavp_copy, 3, - pv_xavp_copy_fixup, 0, ANY_ROUTE}, + pv_xavp_copy_fixup, fixup_free_fparam_all, ANY_ROUTE}, {"xavp_copy", (cmd_function)w_xavp_copy_dst, 4, - pv_xavp_copy_fixup, 0, ANY_ROUTE}, + pv_xavp_copy_fixup, fixup_free_fparam_all, ANY_ROUTE}, {"xavp_slist_explode", (cmd_function)w_xavp_slist_explode, 4, fixup_spve_all, fixup_free_spve_all, ANY_ROUTE}, {"xavp_params_explode", (cmd_function)w_xavp_params_explode, 2,
1 month
1
0
0
0
← Newer
1
...
6
7
8
9
10
11
12
...
37
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
Results per page:
10
25
50
100
200