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
December 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
17 participants
312 discussions
Start a n
N
ew thread
git:master:e658599e: msrp: reformat exported structures
by Victor Seva
Module: kamailio Branch: master Commit: e658599e737c9f2a5eb4384eebd119627a176cdb URL:
https://github.com/kamailio/kamailio/commit/e658599e737c9f2a5eb4384eebd1196…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:55:08+01:00 msrp: reformat exported structures --- Modified: src/modules/msrp/msrp_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/e658599e737c9f2a5eb4384eebd1196…
Patch:
https://github.com/kamailio/kamailio/commit/e658599e737c9f2a5eb4384eebd1196…
1 week, 3 days
1
0
0
0
git:master:2a8df7f1: mtree: add fixup_free* to exported functions
by Victor Seva
Module: kamailio Branch: master Commit: 2a8df7f1e7f77bcfac49a85d0d8c7b283de13be8 URL:
https://github.com/kamailio/kamailio/commit/2a8df7f1e7f77bcfac49a85d0d8c7b2…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:51:15+01:00 mtree: add fixup_free* to exported functions --- Modified: src/modules/mtree/mtree_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/2a8df7f1e7f77bcfac49a85d0d8c7b2…
Patch:
https://github.com/kamailio/kamailio/commit/2a8df7f1e7f77bcfac49a85d0d8c7b2…
--- diff --git a/src/modules/mtree/mtree_mod.c b/src/modules/mtree/mtree_mod.c index 2b8d2adc750..cc3f68d4a7e 100644 --- a/src/modules/mtree/mtree_mod.c +++ b/src/modules/mtree/mtree_mod.c @@ -108,6 +108,7 @@ static volatile int mt_reload_flag = 0; int mt_param(modparam_t type, void *val); static int fixup_mt_match(void **param, int param_no); +static int fixup_free_mt_match(void **param, int param_no); static int w_mt_match(struct sip_msg *msg, char *str1, char *str2, char *str3); static int mod_init(void); @@ -124,7 +125,7 @@ static int mt_load_db_trees(); /* clang-format off */ static cmd_export_t cmds[] = { {"mt_match", (cmd_function)w_mt_match, 3, - fixup_mt_match, 0, + fixup_mt_match, fixup_free_mt_match, REQUEST_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE | ONREPLY_ROUTE}, {"bind_mtree", (cmd_function)bind_mtree, 0, 0, 0}, {0, 0, 0, 0, 0, 0} @@ -336,6 +337,17 @@ static int fixup_mt_match(void **param, int param_no) return fixup_igp_null(param, 1); } +static int fixup_free_mt_match(void **param, int param_no) +{ + if(param_no == 1 || param_no == 2) { + return fixup_free_spve_null(param, 1); + } + if(param_no != 3) { + LM_ERR("invalid parameter number %d\n", param_no); + return E_UNSPEC; + } + return fixup_free_igp_null(param, 1); +} /* use tree tn, match var, by mode, output in avp params */ static int mt_match(sip_msg_t *msg, str *tname, str *tomatch, int mval)
1 week, 3 days
1
0
0
0
git:master:a7a38605: mtree: reformat exported structures
by Victor Seva
Module: kamailio Branch: master Commit: a7a386056040db183abdeff6492773141ca9a92c URL:
https://github.com/kamailio/kamailio/commit/a7a386056040db183abdeff64927731…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:50:13+01:00 mtree: reformat exported structures --- Modified: src/modules/mtree/mtree_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/a7a386056040db183abdeff64927731…
Patch:
https://github.com/kamailio/kamailio/commit/a7a386056040db183abdeff64927731…
--- diff --git a/src/modules/mtree/mtree_mod.c b/src/modules/mtree/mtree_mod.c index ca180d8b534..2b8d2adc750 100644 --- a/src/modules/mtree/mtree_mod.c +++ b/src/modules/mtree/mtree_mod.c @@ -121,40 +121,48 @@ static int mt_match(sip_msg_t *msg, str *tname, str *tomatch, int mval); static int mt_load_db(m_tree_t *pt); static int mt_load_db_trees(); +/* clang-format off */ static cmd_export_t cmds[] = { - {"mt_match", (cmd_function)w_mt_match, 3, fixup_mt_match, 0, - REQUEST_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE | ONREPLY_ROUTE}, - {"bind_mtree", (cmd_function)bind_mtree, 0, 0, 0}, {0, 0, 0, 0, 0, 0}}; + {"mt_match", (cmd_function)w_mt_match, 3, + fixup_mt_match, 0, + REQUEST_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE | ONREPLY_ROUTE}, + {"bind_mtree", (cmd_function)bind_mtree, 0, 0, 0}, + {0, 0, 0, 0, 0, 0} +}; static param_export_t params[] = { - {"mtree", PARAM_STRING | PARAM_USE_FUNC, (void *)mt_param}, - {"db_url", PARAM_STR, &db_url}, {"db_table", PARAM_STR, &db_table}, - {"tname_column", PARAM_STR, &tname_column}, - {"tprefix_column", PARAM_STR, &tprefix_column}, - {"tvalue_column", PARAM_STR, &tvalue_column}, - {"char_list", PARAM_STR, &mt_char_list}, - {"fetch_rows", PARAM_INT, &mt_fetch_rows}, - {"pv_value", PARAM_STR, &value_param}, - {"pv_values", PARAM_STR, &values_param}, - {"pv_dstid", PARAM_STR, &dstid_param}, - {"pv_weight", PARAM_STR, &weight_param}, - {"pv_count", PARAM_STR, &count_param}, - {"mt_tree_type", PARAM_INT, &_mt_tree_type}, - {"mt_ignore_duplicates", PARAM_INT, &_mt_ignore_duplicates}, - {"mt_allow_duplicates", PARAM_INT, &_mt_allow_duplicates}, {0, 0, 0}}; + {"mtree", PARAM_STRING | PARAM_USE_FUNC, (void *)mt_param}, + {"db_url", PARAM_STR, &db_url}, + {"db_table", PARAM_STR, &db_table}, + {"tname_column", PARAM_STR, &tname_column}, + {"tprefix_column", PARAM_STR, &tprefix_column}, + {"tvalue_column", PARAM_STR, &tvalue_column}, + {"char_list", PARAM_STR, &mt_char_list}, + {"fetch_rows", PARAM_INT, &mt_fetch_rows}, + {"pv_value", PARAM_STR, &value_param}, + {"pv_values", PARAM_STR, &values_param}, + {"pv_dstid", PARAM_STR, &dstid_param}, + {"pv_weight", PARAM_STR, &weight_param}, + {"pv_count", PARAM_STR, &count_param}, + {"mt_tree_type", PARAM_INT, &_mt_tree_type}, + {"mt_ignore_duplicates", PARAM_INT, &_mt_ignore_duplicates}, + {"mt_allow_duplicates", PARAM_INT, &_mt_allow_duplicates}, + {0, 0, 0} +}; struct module_exports exports = { - "mtree", DEFAULT_DLFLAGS, /* dlopen flags */ - cmds, /*��exported��functions��*/ - params, /*��exported��functions��*/ - 0, /*��exported��RPC��methods��*/ - 0, /* exported pseudo-variables */ - 0, /* response��function */ - mod_init, /* module initialization function */ - child_init, /* per child init function */ - mod_destroy /* destroy function */ + "mtree", + DEFAULT_DLFLAGS, /* dlopen flags */ + cmds, /*��exported��functions��*/ + params, /*��exported��functions��*/ + 0, /*��exported��RPC��methods��*/ + 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
1 week, 3 days
1
0
0
0
git:master:259935c2: nat_traversal: add fixup_free* to exported functions
by Victor Seva
Module: kamailio Branch: master Commit: 259935c2a2d5c367ef4773826bb69faec8256dee URL:
https://github.com/kamailio/kamailio/commit/259935c2a2d5c367ef4773826bb69fa…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:23:15+01:00 nat_traversal: add fixup_free* to exported functions --- Modified: src/modules/nat_traversal/nat_traversal.c --- Diff:
https://github.com/kamailio/kamailio/commit/259935c2a2d5c367ef4773826bb69fa…
Patch:
https://github.com/kamailio/kamailio/commit/259935c2a2d5c367ef4773826bb69fa…
--- diff --git a/src/modules/nat_traversal/nat_traversal.c b/src/modules/nat_traversal/nat_traversal.c index f3d687ff1d6..0f952f01d66 100644 --- a/src/modules/nat_traversal/nat_traversal.c +++ b/src/modules/nat_traversal/nat_traversal.c @@ -285,7 +285,7 @@ static cmd_export_t commands[] = { {"fix_contact", (cmd_function)w_FixContact, 0, 0, 0, ANY_ROUTE}, {"client_nat_test", (cmd_function)w_ClientNatTest, 1, - fixup_igp_null, 0, ANY_ROUTE}, + fixup_igp_null, fixup_free_igp_null, ANY_ROUTE}, {0, 0, 0, 0, 0, 0} };
1 week, 3 days
1
0
0
0
git:master:0ebc38a4: nat_traversal: reformat exported structures
by Victor Seva
Module: kamailio Branch: master Commit: 0ebc38a4834d74dfee8ff7326e516c01d7273472 URL:
https://github.com/kamailio/kamailio/commit/0ebc38a4834d74dfee8ff7326e516c0…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:22:53+01:00 nat_traversal: reformat exported structures --- Modified: src/modules/nat_traversal/nat_traversal.c --- Diff:
https://github.com/kamailio/kamailio/commit/0ebc38a4834d74dfee8ff7326e516c0…
Patch:
https://github.com/kamailio/kamailio/commit/0ebc38a4834d74dfee8ff7326e516c0…
1 week, 3 days
1
0
0
0
git:master:9dc92332: nathelper: add fixup_free* to exported functions
by Victor Seva
Module: kamailio Branch: master Commit: 9dc9233289d2518419438d38ac7d7b0abf4862a1 URL:
https://github.com/kamailio/kamailio/commit/9dc9233289d2518419438d38ac7d7b0…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:18:46+01:00 nathelper: add fixup_free* to exported functions --- Modified: src/modules/nathelper/nathelper.c --- Diff:
https://github.com/kamailio/kamailio/commit/9dc9233289d2518419438d38ac7d7b0…
Patch:
https://github.com/kamailio/kamailio/commit/9dc9233289d2518419438d38ac7d7b0…
--- diff --git a/src/modules/nathelper/nathelper.c b/src/modules/nathelper/nathelper.c index 6673370a5a8..ec543079f31 100644 --- a/src/modules/nathelper/nathelper.c +++ b/src/modules/nathelper/nathelper.c @@ -125,7 +125,9 @@ static int alter_mediaip(struct sip_msg *, str *, str *, int, str *, int, int); static int fix_nated_register_f(struct sip_msg *, char *, char *); static int fixup_fix_nated_register(void **param, int param_no); static int fixup_fix_sdp(void **param, int param_no); +static int fixup_free_fix_sdp(void **param, int param_no); static int fixup_add_contact_alias(void **param, int param_no); +static int fixup_free_add_contact_alias(void **param, int param_no); static int add_rcv_param_f(struct sip_msg *, char *, char *); static int nh_sip_reply_received(sip_msg_t *msg); static int test_sdp_cline(struct sip_msg *msg); @@ -214,7 +216,7 @@ static cmd_export_t cmds[] = { 0, 0, REQUEST_ROUTE|ONREPLY_ROUTE|BRANCH_ROUTE|LOCAL_ROUTE}, {"add_contact_alias", (cmd_function)add_contact_alias_3_f, 3, - fixup_add_contact_alias, 0, + fixup_add_contact_alias, fixup_free_add_contact_alias, REQUEST_ROUTE|ONREPLY_ROUTE|BRANCH_ROUTE|FAILURE_ROUTE}, {"set_contact_alias", (cmd_function)set_contact_alias_f, 0, 0, 0, @@ -228,13 +230,13 @@ static cmd_export_t cmds[] = { fixup_igp_null, fixup_free_igp_null, REQUEST_ROUTE|BRANCH_ROUTE|LOCAL_ROUTE}, {"fix_nated_sdp", (cmd_function)fix_nated_sdp_f, 1, - fixup_fix_sdp, 0, + fixup_fix_sdp, fixup_free_fix_sdp, REQUEST_ROUTE|ONREPLY_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|LOCAL_ROUTE}, {"fix_nated_sdp", (cmd_function)fix_nated_sdp_f, 2, - fixup_fix_sdp, 0, + fixup_fix_sdp, fixup_free_fix_sdp, REQUEST_ROUTE|ONREPLY_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|LOCAL_ROUTE}, {"nat_uac_test", (cmd_function)nat_uac_test_f, 1, - fixup_igp_null, 0, + fixup_igp_null, fixup_free_igp_null, REQUEST_ROUTE|ONREPLY_ROUTE|FAILURE_ROUTE|BRANCH_ROUTE|LOCAL_ROUTE}, {"fix_nated_register", (cmd_function)fix_nated_register_f, 0, fixup_fix_nated_register, 0, @@ -243,10 +245,10 @@ static cmd_export_t cmds[] = { 0, 0, REQUEST_ROUTE }, {"add_rcv_param", (cmd_function)add_rcv_param_f, 1, - fixup_igp_null, 0, + fixup_igp_null, fixup_free_igp_null, REQUEST_ROUTE }, {"is_rfc1918", (cmd_function)is_rfc1918_f, 1, - fixup_spve_null, 0, + fixup_spve_null, fixup_free_spve_null, ANY_ROUTE }, {"set_alias_to_pv", (cmd_function)w_set_alias_to_pv, 1, 0, 0, ANY_ROUTE }, @@ -333,6 +335,20 @@ static int fixup_fix_sdp(void **param, int param_no) return -1; } +static int fixup_free_fix_sdp(void **param, int param_no) +{ + if(param_no == 1) { + /* flags */ + return fixup_free_igp_null(param, param_no); + } + if(param_no == 2) { + /* new IP */ + return fixup_free_spve_all(param, param_no); + } + LM_ERR("unexpected param no: %d\n", param_no); + return -1; +} + static int fixup_fix_nated_register(void **param, int param_no) { if(rcv_avp_name.n == 0) { @@ -352,6 +368,15 @@ static int fixup_add_contact_alias(void **param, int param_no) return -1; } +static int fixup_free_add_contact_alias(void **param, int param_no) +{ + if((param_no >= 1) && (param_no <= 3)) + return fixup_free_spve_null(param, 1); + + LM_ERR("invalid parameter number <%d>\n", param_no); + return -1; +} + static void nathelper_rpc_enable_ping(rpc_t *rpc, void *ctx) { int value = 0;
1 week, 3 days
1
0
0
0
git:master:6ca7a392: ndb_cassandra: add fixup_free* to exported functions
by Victor Seva
Module: kamailio Branch: master Commit: 6ca7a392708a1ea6a38c791591272bdf5b299832 URL:
https://github.com/kamailio/kamailio/commit/6ca7a392708a1ea6a38c791591272bd…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:14:30+01:00 ndb_cassandra: add fixup_free* to exported functions --- Modified: src/modules/ndb_cassandra/ndb_cassandra.c --- Diff:
https://github.com/kamailio/kamailio/commit/6ca7a392708a1ea6a38c791591272bd…
Patch:
https://github.com/kamailio/kamailio/commit/6ca7a392708a1ea6a38c791591272bd…
--- diff --git a/src/modules/ndb_cassandra/ndb_cassandra.c b/src/modules/ndb_cassandra/ndb_cassandra.c index 7de3d608fda..375e8bf3fd8 100644 --- a/src/modules/ndb_cassandra/ndb_cassandra.c +++ b/src/modules/ndb_cassandra/ndb_cassandra.c @@ -55,7 +55,7 @@ static void destroy(void); /* Fixups functions */ static int fixup_cass_insert(void **param, int param_no); - +static int fixup_free_cass_insert(void **param, int param_no); static int fixup_cass_retrieve(void **param, int param_no); static int free_fixup_cass_retrieve(void **param, int param_no); @@ -69,7 +69,7 @@ static int cass_retrieve_f(struct sip_msg *msg, char *keyspace, /* Exported functions */ static cmd_export_t cmds[] = { {"cass_insert", (cmd_function)cass_insert_f, 5, - fixup_cass_insert, 0, + fixup_cass_insert, fixup_free_cass_insert, REQUEST_ROUTE | ONREPLY_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE}, {"cass_retrieve", (cmd_function)cass_retrieve_f, 5, fixup_cass_retrieve, free_fixup_cass_retrieve, @@ -137,6 +137,28 @@ static int fixup_cass_insert(void **param, int param_no) LM_ERR("invalid parameter number <%d>\n", param_no); return -1; } + +static int fixup_free_cass_insert(void **param, int param_no) +{ + if(param_no == 1) { + return fixup_free_spve_null(param, 1); + } + if(param_no == 2) { + return fixup_free_spve_null(param, 1); + } + if(param_no == 3) { + return fixup_free_spve_null(param, 1); + } + if(param_no == 4) { + return fixup_free_spve_null(param, 1); + } + if(param_no == 5) { + return fixup_free_spve_null(param, 1); + } + LM_ERR("invalid parameter number <%d>\n", param_no); + return -1; +} + /**/ static int fixup_cass_retrieve(void **param, int param_no) { @@ -171,20 +193,16 @@ static int fixup_cass_retrieve(void **param, int param_no) static int free_fixup_cass_retrieve(void **param, int param_no) { if(param_no == 1) { - LM_WARN("free function has not been defined for spve\n"); - return 0; + return fixup_free_spve_null(param, 1); } if(param_no == 2) { - LM_WARN("free function has not been defined for spve\n"); - return 0; + return fixup_free_spve_null(param, 1); } if(param_no == 3) { - LM_WARN("free function has not been defined for spve\n"); - return 0; + return fixup_free_spve_null(param, 1); } if(param_no == 4) { - LM_WARN("free function has not been defined for spve\n"); - return 0; + return fixup_free_spve_null(param, 1); } if(param_no == 5) { return fixup_free_pvar_null(param, 1);
1 week, 3 days
1
0
0
0
git:master:8e2a41e5: ndb_cassandra: reformat exported structures
by Victor Seva
Module: kamailio Branch: master Commit: 8e2a41e57ab428f64cc78a76ea4716186357b9d5 URL:
https://github.com/kamailio/kamailio/commit/8e2a41e57ab428f64cc78a76ea47161…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:14:11+01:00 ndb_cassandra: reformat exported structures --- Modified: src/modules/ndb_cassandra/ndb_cassandra.c --- Diff:
https://github.com/kamailio/kamailio/commit/8e2a41e57ab428f64cc78a76ea47161…
Patch:
https://github.com/kamailio/kamailio/commit/8e2a41e57ab428f64cc78a76ea47161…
--- diff --git a/src/modules/ndb_cassandra/ndb_cassandra.c b/src/modules/ndb_cassandra/ndb_cassandra.c index eb748c914f9..7de3d608fda 100644 --- a/src/modules/ndb_cassandra/ndb_cassandra.c +++ b/src/modules/ndb_cassandra/ndb_cassandra.c @@ -65,31 +65,39 @@ static int cass_insert_f(struct sip_msg *msg, char *keyspace, static int cass_retrieve_f(struct sip_msg *msg, char *keyspace, char *column_family, char *key, char *column, char *value); +/* clang-format off */ /* Exported functions */ static cmd_export_t cmds[] = { - {"cass_insert", (cmd_function)cass_insert_f, 5, fixup_cass_insert, 0, - REQUEST_ROUTE | ONREPLY_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE}, - {"cass_retrieve", (cmd_function)cass_retrieve_f, 5, fixup_cass_retrieve, - free_fixup_cass_retrieve, - REQUEST_ROUTE | ONREPLY_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE}, - {0, 0, 0, 0, 0, 0}}; + {"cass_insert", (cmd_function)cass_insert_f, 5, + fixup_cass_insert, 0, + REQUEST_ROUTE | ONREPLY_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE}, + {"cass_retrieve", (cmd_function)cass_retrieve_f, 5, + fixup_cass_retrieve, free_fixup_cass_retrieve, + REQUEST_ROUTE | ONREPLY_ROUTE | FAILURE_ROUTE | BRANCH_ROUTE}, + {0, 0, 0, 0, 0, 0} +}; /* Exported parameters */ static param_export_t params[] = { - {"host", PARAM_STR, &host}, {"port", PARAM_INT, &port}, {0, 0, 0}}; + {"host", PARAM_STR, &host}, + {"port", PARAM_INT, &port}, + {0, 0, 0} +}; /* Module interface */ struct module_exports exports = { - "ndb_cassandra", DEFAULT_DLFLAGS, /* dlopen flags */ - cmds, /* Exported functions */ - params, /* Exported parameters */ - 0, /* exported RPC methods */ - 0, /* exported pseudo-variables */ - 0, /* response function*/ - mod_init, /* module initialization function */ - child_init, /* per-child init function */ - destroy /* destroy function */ + "ndb_cassandra", + DEFAULT_DLFLAGS, /* dlopen flags */ + cmds, /* Exported functions */ + params, /* Exported parameters */ + 0, /* exported RPC methods */ + 0, /* exported pseudo-variables */ + 0, /* response function*/ + mod_init, /* module initialization function */ + child_init, /* per-child init function */ + destroy /* destroy function */ }; +/* clang-format on */ /* Module initialization function */ static int mod_init(void)
1 week, 3 days
1
0
0
0
git:master:2e341d4d: ndb_mongodb: add fixup_free* to exported functions
by Victor Seva
Module: kamailio Branch: master Commit: 2e341d4d89f228e4f6910c564c16fde1d9a64b1a URL:
https://github.com/kamailio/kamailio/commit/2e341d4d89f228e4f6910c564c16fde…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T15:01:30+01:00 ndb_mongodb: add fixup_free* to exported functions --- Modified: src/modules/ndb_mongodb/ndb_mongodb_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/2e341d4d89f228e4f6910c564c16fde…
Patch:
https://github.com/kamailio/kamailio/commit/2e341d4d89f228e4f6910c564c16fde…
--- diff --git a/src/modules/ndb_mongodb/ndb_mongodb_mod.c b/src/modules/ndb_mongodb/ndb_mongodb_mod.c index 46cb8ec5045..6babeeaccd6 100644 --- a/src/modules/ndb_mongodb/ndb_mongodb_mod.c +++ b/src/modules/ndb_mongodb/ndb_mongodb_mod.c @@ -50,6 +50,7 @@ static int w_mongodb_cmd_simple(sip_msg_t *msg, char *ssrv, char *sdname, static int w_mongodb_cmd(sip_msg_t *msg, char *ssrv, char *sdname, char *scname, char *scmd, char *sres); static int fixup_mongodb_cmd(void **param, int param_no); +static int fixup_free_mongodb_cmd(void **param, int param_no); static int w_mongodb_free_reply(struct sip_msg *msg, char *res); static int w_mongodb_next_reply(struct sip_msg *msg, char *res); @@ -69,17 +70,17 @@ static pv_export_t mod_pvs[] = { static cmd_export_t cmds[] = { {"mongodb_find", (cmd_function)w_mongodb_find, 5, - fixup_mongodb_cmd, 0, ANY_ROUTE}, + fixup_mongodb_cmd, fixup_free_mongodb_cmd, ANY_ROUTE}, {"mongodb_find_one", (cmd_function)w_mongodb_find_one, 5, - fixup_mongodb_cmd, 0, ANY_ROUTE}, + fixup_mongodb_cmd, fixup_free_mongodb_cmd, ANY_ROUTE}, {"mongodb_cmd_simple", (cmd_function)w_mongodb_cmd_simple, 5, - fixup_mongodb_cmd, 0, ANY_ROUTE}, + fixup_mongodb_cmd, fixup_free_mongodb_cmd, ANY_ROUTE}, {"mongodb_cmd", (cmd_function)w_mongodb_cmd, 5, - fixup_mongodb_cmd, 0, ANY_ROUTE}, + fixup_mongodb_cmd, fixup_free_mongodb_cmd, ANY_ROUTE}, {"mongodb_free", (cmd_function)w_mongodb_free_reply, 1, - fixup_spve_null, 0, ANY_ROUTE}, + fixup_spve_null, fixup_free_spve_null, ANY_ROUTE}, {"mongodb_next", (cmd_function)w_mongodb_next_reply, 1, - fixup_spve_null, 0, ANY_ROUTE}, + fixup_spve_null, fixup_free_spve_null, ANY_ROUTE}, {"bind_ndb_mongodb", (cmd_function)bind_ndb_mongodb, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0} }; @@ -250,6 +251,11 @@ static int fixup_mongodb_cmd(void **param, int param_no) return fixup_spve_null(param, 1); } +static int fixup_free_mongodb_cmd(void **param, int param_no) +{ + return fixup_free_spve_null(param, 1); +} + /** * */
1 week, 3 days
1
0
0
0
git:master:e5c7b4ea: ndb_mongodb: reformat exported structures
by Victor Seva
Module: kamailio Branch: master Commit: e5c7b4ea8246f11815ab49fa0219ce2a7be3dd65 URL:
https://github.com/kamailio/kamailio/commit/e5c7b4ea8246f11815ab49fa0219ce2…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org> Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org> Date: 2024-12-12T14:59:53+01:00 ndb_mongodb: reformat exported structures --- Modified: src/modules/ndb_mongodb/ndb_mongodb_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/e5c7b4ea8246f11815ab49fa0219ce2…
Patch:
https://github.com/kamailio/kamailio/commit/e5c7b4ea8246f11815ab49fa0219ce2…
--- diff --git a/src/modules/ndb_mongodb/ndb_mongodb_mod.c b/src/modules/ndb_mongodb/ndb_mongodb_mod.c index a778a492f38..46cb8ec5045 100644 --- a/src/modules/ndb_mongodb/ndb_mongodb_mod.c +++ b/src/modules/ndb_mongodb/ndb_mongodb_mod.c @@ -60,44 +60,48 @@ static int pv_get_mongodb( struct sip_msg *msg, pv_param_t *param, pv_value_t *res); static int pv_parse_mongodb_name(pv_spec_p sp, str *in); +/* clang-format off */ static pv_export_t mod_pvs[] = { - {{"mongodb", sizeof("mongodb") - 1}, PVT_OTHER, pv_get_mongodb, 0, - pv_parse_mongodb_name, 0, 0, 0}, - {{0, 0}, 0, 0, 0, 0, 0, 0, 0}}; - - -static cmd_export_t cmds[] = {{"mongodb_find", (cmd_function)w_mongodb_find, 5, - fixup_mongodb_cmd, 0, ANY_ROUTE}, - {"mongodb_find_one", (cmd_function)w_mongodb_find_one, 5, - fixup_mongodb_cmd, 0, ANY_ROUTE}, - {"mongodb_cmd_simple", (cmd_function)w_mongodb_cmd_simple, 5, - fixup_mongodb_cmd, 0, ANY_ROUTE}, - {"mongodb_cmd", (cmd_function)w_mongodb_cmd, 5, fixup_mongodb_cmd, 0, - ANY_ROUTE}, - {"mongodb_free", (cmd_function)w_mongodb_free_reply, 1, fixup_spve_null, - 0, ANY_ROUTE}, - {"mongodb_next", (cmd_function)w_mongodb_next_reply, 1, fixup_spve_null, - 0, ANY_ROUTE}, - {"bind_ndb_mongodb", (cmd_function)bind_ndb_mongodb, 0, 0, 0, 0}, - {0, 0, 0, 0, 0, 0}}; + {{"mongodb", sizeof("mongodb") - 1}, PVT_OTHER, pv_get_mongodb, 0, + pv_parse_mongodb_name, 0, 0, 0}, + {{0, 0}, 0, 0, 0, 0, 0, 0, 0} +}; + +static cmd_export_t cmds[] = { + {"mongodb_find", (cmd_function)w_mongodb_find, 5, + fixup_mongodb_cmd, 0, ANY_ROUTE}, + {"mongodb_find_one", (cmd_function)w_mongodb_find_one, 5, + fixup_mongodb_cmd, 0, ANY_ROUTE}, + {"mongodb_cmd_simple", (cmd_function)w_mongodb_cmd_simple, 5, + fixup_mongodb_cmd, 0, ANY_ROUTE}, + {"mongodb_cmd", (cmd_function)w_mongodb_cmd, 5, + fixup_mongodb_cmd, 0, ANY_ROUTE}, + {"mongodb_free", (cmd_function)w_mongodb_free_reply, 1, + fixup_spve_null, 0, ANY_ROUTE}, + {"mongodb_next", (cmd_function)w_mongodb_next_reply, 1, + fixup_spve_null, 0, ANY_ROUTE}, + {"bind_ndb_mongodb", (cmd_function)bind_ndb_mongodb, 0, 0, 0, 0}, + {0, 0, 0, 0, 0, 0} +}; static param_export_t params[] = { - {"server", PARAM_STRING | PARAM_USE_FUNC, (void *)mongodb_srv_param}, - {0, 0, 0}}; + {"server", PARAM_STRING | PARAM_USE_FUNC, (void *)mongodb_srv_param}, + {0, 0, 0} +}; struct module_exports exports = { - "ndb_mongodb", /* module name */ - DEFAULT_DLFLAGS, /* dlopen flags */ - cmds, /*��exported��functions��*/ - params, /*��exported��params��*/ - 0, /*��exported��RPC��methods��*/ - mod_pvs, /* exported pseudo-variables */ - 0, /* response function */ - 0, /* module��initialization��function */ - child_init, /* per child init function */ - mod_destroy /* destroy function */ + "ndb_mongodb", /* module name */ + DEFAULT_DLFLAGS, /* dlopen flags */ + cmds, /*��exported��functions��*/ + params, /*��exported��params��*/ + 0, /*��exported��RPC��methods��*/ + mod_pvs, /* exported pseudo-variables */ + 0, /* response function */ + 0, /* module��initialization��function */ + child_init, /* per child init function */ + mod_destroy /* destroy function */ }; - +/* clang-format on */ /* each child get a new connection to the database */ static int child_init(int rank)
1 week, 3 days
1
0
0
0
← Newer
1
...
13
14
15
16
17
18
19
...
32
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
Results per page:
10
25
50
100
200