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
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
April 2023
----- 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
15 participants
263 discussions
Start a n
N
ew thread
git:master:fc52a1e7: prefix_route: convert to memory logging helper, add missing logging
by Henning Westerholt
Module: kamailio Branch: master Commit: fc52a1e73812daaef425727fcf5f59ed6b75b2f9 URL:
https://github.com/kamailio/kamailio/commit/fc52a1e73812daaef425727fcf5f59e…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:35:41Z prefix_route: convert to memory logging helper, add missing logging --- Modified: src/modules/prefix_route/tree.c --- Diff:
https://github.com/kamailio/kamailio/commit/fc52a1e73812daaef425727fcf5f59e…
Patch:
https://github.com/kamailio/kamailio/commit/fc52a1e73812daaef425727fcf5f59e…
--- diff --git a/src/modules/prefix_route/tree.c b/src/modules/prefix_route/tree.c index a90144d63af..c5e55826539 100644 --- a/src/modules/prefix_route/tree.c +++ b/src/modules/prefix_route/tree.c @@ -72,7 +72,7 @@ struct tree_item *tree_item_alloc(void) root = (struct tree_item *)shm_malloc(sizeof(*root)); if (NULL == root) { - LM_CRIT("shared memory alloc failed\n"); + SHM_MEM_CRITICAL; return NULL; } @@ -241,8 +241,10 @@ static struct tree *tree_alloc(void) struct tree *tree; tree = (struct tree *)shm_malloc(sizeof(*tree)); - if (NULL == tree) + if (NULL == tree) { + SHM_MEM_CRITICAL; return NULL; + } tree->root = NULL; atomic_set(&tree->refcnt, 0); @@ -325,6 +327,7 @@ int tree_init(void) /* Pointer to global tree must be in shared memory */ shared_tree = (struct tree **)shm_malloc(sizeof(*shared_tree)); if (NULL == shared_tree) { + SHM_MEM_ERROR; lock_destroy(shared_tree_lock); lock_dealloc(shared_tree_lock); shared_tree_lock=0;
1 year, 5 months
1
0
0
0
git:master:56a843bb: dmq_usrloc: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: 56a843bb18b5f06d4ef88ed525d446a1ff298b3f URL:
https://github.com/kamailio/kamailio/commit/56a843bb18b5f06d4ef88ed525d446a…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:32:29Z dmq_usrloc: convert to memory logging helper --- Modified: src/modules/dmq_usrloc/usrloc_sync.c --- Diff:
https://github.com/kamailio/kamailio/commit/56a843bb18b5f06d4ef88ed525d446a…
Patch:
https://github.com/kamailio/kamailio/commit/56a843bb18b5f06d4ef88ed525d446a…
--- diff --git a/src/modules/dmq_usrloc/usrloc_sync.c b/src/modules/dmq_usrloc/usrloc_sync.c index 62477198a27..657db6cb7cb 100644 --- a/src/modules/dmq_usrloc/usrloc_sync.c +++ b/src/modules/dmq_usrloc/usrloc_sync.c @@ -203,7 +203,7 @@ void usrloc_get_all_ucontact(dmq_node_t* node) len = rval * 2; buf = dmq_usrloc_malloc(len); if (buf == NULL) { - LM_ERR("out of pkg memory\n"); + PKG_MEM_ERROR; goto done; } rval = dmq_ul.get_all_ucontacts(buf, len, 0, 0, 1, 0); @@ -453,7 +453,7 @@ static int init_usrloc_dmq_recv() { LM_DBG("Initializing usrloc_dmq_recv for pid (%d)\n", my_pid()); usrloc_dmq_recv = (int*)pkg_malloc(sizeof(int)); if (!usrloc_dmq_recv) { - LM_ERR("no more pkg memory\n"); + PKG_MEM_ERROR; return -1; } *usrloc_dmq_recv = 0;
1 year, 5 months
1
0
0
0
git:master:a3fe9388: path: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: a3fe9388540ee3ba0331b642e1c26170ca572e60 URL:
https://github.com/kamailio/kamailio/commit/a3fe9388540ee3ba0331b642e1c2617…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:30:54Z path: convert to memory logging helper --- Modified: src/modules/path/path.c --- Diff:
https://github.com/kamailio/kamailio/commit/a3fe9388540ee3ba0331b642e1c2617…
Patch:
https://github.com/kamailio/kamailio/commit/a3fe9388540ee3ba0331b642e1c2617…
--- diff --git a/src/modules/path/path.c b/src/modules/path/path.c index c90aa939004..f1d8a624646 100644 --- a/src/modules/path/path.c +++ b/src/modules/path/path.c @@ -68,8 +68,10 @@ static char *path_strzdup(char *src, int len) if(len<0) { len = strlen(src); } - if (!(res = (char *) pkg_malloc(len + 1))) + if (!(res = (char *) pkg_malloc(len + 1))) { + PKG_MEM_ERROR; return NULL; + } strncpy(res, src, len); res[len] = 0; @@ -112,7 +114,7 @@ static int prepend_path(sip_msg_t* _m, str *user, path_param_t param, cp = suffix = pkg_malloc(suffix_len); if (!suffix) { - LM_ERR("no pkg memory left for suffix\n"); + PKG_MEM_ERROR_FMT("for suffix\n"); goto out1; } @@ -165,7 +167,7 @@ static int prepend_path(sip_msg_t* _m, str *user, path_param_t param, prefix_len = PATH_PREFIX_LEN + (user ? user->len : 0) + 2; prefix = pkg_malloc(prefix_len); if (!prefix) { - LM_ERR("no pkg memory left for prefix\n"); + PKG_MEM_ERROR_FMT("for prefix\n"); goto out2; } if (user && user->len)
1 year, 5 months
1
0
0
0
git:master:4f44adcf: outbound: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: 4f44adcfbfaf84262f09f03afd8912205ce6c13b URL:
https://github.com/kamailio/kamailio/commit/4f44adcfbfaf84262f09f03afd89122…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:27:45Z outbound: convert to memory logging helper --- Modified: src/modules/outbound/outbound_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/4f44adcfbfaf84262f09f03afd89122…
Patch:
https://github.com/kamailio/kamailio/commit/4f44adcfbfaf84262f09f03afd89122…
--- diff --git a/src/modules/outbound/outbound_mod.c b/src/modules/outbound/outbound_mod.c index df9538aace8..bed8c03fbb4 100644 --- a/src/modules/outbound/outbound_mod.c +++ b/src/modules/outbound/outbound_mod.c @@ -101,7 +101,7 @@ static int mod_init(void) if ((ob_key.s = shm_malloc(OB_KEY_LEN)) == NULL) { - LM_ERR("Failed to allocate memory for flow-token key\n"); + SHM_MEM_ERROR_FMT("for flow-token key\n"); return -1; } ob_key.len = OB_KEY_LEN; @@ -210,7 +210,7 @@ int encode_flow_token(str *flow_token, struct receive_info *rcv) flow_token->s = pkg_malloc(base64_enc_len(pos)); if (flow_token->s == NULL) { - LM_ERR("allocating package memory\n"); + PKG_MEM_ERROR; return -1; } flow_token->len = base64_enc(unenc_flow_token, pos,
1 year, 5 months
1
0
0
0
git:master:965606b2: rr: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: 965606b2fbdad7b868637fb2f35f15507279caf6 URL:
https://github.com/kamailio/kamailio/commit/965606b2fbdad7b868637fb2f35f155…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:26:44Z rr: convert to memory logging helper --- Modified: src/modules/rr/loose.c Modified: src/modules/rr/record.c Modified: src/modules/rr/rr_cb.c --- Diff:
https://github.com/kamailio/kamailio/commit/965606b2fbdad7b868637fb2f35f155…
Patch:
https://github.com/kamailio/kamailio/commit/965606b2fbdad7b868637fb2f35f155…
--- diff --git a/src/modules/rr/loose.c b/src/modules/rr/loose.c index 8df81d56528..71a38532131 100644 --- a/src/modules/rr/loose.c +++ b/src/modules/rr/loose.c @@ -316,7 +316,7 @@ static inline int save_ruri(struct sip_msg* _m) + ROUTE_SUFFIX_LEN; s = (char*)pkg_malloc(len); if (!s) { - LM_ERR("No memory pkg left\n"); + PKG_MEM_ERROR; return -3; } diff --git a/src/modules/rr/record.c b/src/modules/rr/record.c index b6178cade36..01bbd3e4032 100644 --- a/src/modules/rr/record.c +++ b/src/modules/rr/record.c @@ -172,7 +172,7 @@ static inline struct lump *insert_rr_param_lump(struct lump *before, /* duplicate data in pkg mem */ s1 = (char*)pkg_malloc(l); if (s1==0) { - LM_ERR("no more pkg mem (%d)\n",l); + PKG_MEM_ERROR_FMT("missing (%d)\n",l); return 0; } memcpy( s1, s, l); @@ -233,7 +233,7 @@ static inline int build_rr(struct lump* _l, struct lump* _l2, str* user, r2 = pkg_malloc(RR_R2_LEN); if (!prefix || !suffix || !term || !r2) { - LM_ERR("No more pkg memory\n"); + PKG_MEM_ERROR; if (suffix) pkg_free(suffix); if (prefix) pkg_free(prefix); if (term) pkg_free(term); @@ -356,7 +356,7 @@ static int copy_flow_token(str *token, struct sip_msg *_m) token->s = pkg_malloc(puri.user.len * sizeof(char)); if (token->s == NULL) { - LM_ERR("allocating memory\n"); + PKG_MEM_ERROR; return -1; } memcpy(token->s, puri.user.s, puri.user.len); @@ -593,7 +593,7 @@ int record_route_preset(struct sip_msg* _m, str* _data) suffix.s = pkg_malloc(suffix.len); term.s = pkg_malloc(term.len); if (!hdr.s || !suffix.s || !term.s) { - LM_ERR("no pkg memory left\n"); + PKG_MEM_ERROR; if(hdr.s) pkg_free(hdr.s); if(suffix.s) pkg_free(suffix.s); if(term.s) pkg_free(term.s); @@ -719,7 +719,7 @@ static inline int build_advertised_rr(struct lump* _l, struct lump* _l2, str *_d r2 = pkg_malloc(RR_R2_LEN); term = pkg_malloc(RR_TERM_LEN); if (!hdr || !trans || !suffix || !term || !r2) { - LM_ERR("no pkg memory left\n"); + PKG_MEM_ERROR; if (hdr) pkg_free(hdr); if (trans) pkg_free(trans); if (suffix) pkg_free(suffix); diff --git a/src/modules/rr/rr_cb.c b/src/modules/rr/rr_cb.c index 6b66e8c5859..c55f0117295 100644 --- a/src/modules/rr/rr_cb.c +++ b/src/modules/rr/rr_cb.c @@ -59,7 +59,7 @@ int register_rrcb( rr_cb_t f, void *param ) /* build a new callback structure */ if (!(cbp=pkg_malloc( sizeof( struct rr_callback)))) { - LM_ERR("no more pkg mem\n"); + PKG_MEM_ERROR; return -1; }
1 year, 5 months
1
0
0
0
git:master:19df3ad8: uid_auth_db: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: 19df3ad8f3e10b6c9fa91e69f288fdbd51be7091 URL:
https://github.com/kamailio/kamailio/commit/19df3ad8f3e10b6c9fa91e69f288fdb…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:24:24Z uid_auth_db: convert to memory logging helper --- Modified: src/modules/uid_auth_db/aaa_avps.h Modified: src/modules/uid_auth_db/uid_auth_db_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/19df3ad8f3e10b6c9fa91e69f288fdb…
Patch:
https://github.com/kamailio/kamailio/commit/19df3ad8f3e10b6c9fa91e69f288fdb…
--- diff --git a/src/modules/uid_auth_db/aaa_avps.h b/src/modules/uid_auth_db/aaa_avps.h index 62f1062bf3d..25b6cbeda3b 100644 --- a/src/modules/uid_auth_db/aaa_avps.h +++ b/src/modules/uid_auth_db/aaa_avps.h @@ -76,7 +76,7 @@ static int aaa_avps_init(str *avp_list, str **parsed_avps, int *avps_n) cp = pkg_malloc(avp_list->len + 1); if (cp == NULL) { - LM_ERR("can't allocate memory\n"); + PKG_MEM_ERROR; errcode = -1; goto bad; } diff --git a/src/modules/uid_auth_db/uid_auth_db_mod.c b/src/modules/uid_auth_db/uid_auth_db_mod.c index 781ff37220f..2fd206bb970 100644 --- a/src/modules/uid_auth_db/uid_auth_db_mod.c +++ b/src/modules/uid_auth_db/uid_auth_db_mod.c @@ -172,7 +172,7 @@ static int generate_queries(authdb_table_info_t *info) len = sizeof(*result_cols) * (credentials_n + 3); result_cols = pkg_malloc(len); if (!result_cols) { - ERR("can't allocate pkg mem\n"); + PKG_MEM_ERROR; return -1; } memset(result_cols, 0, len); @@ -321,7 +321,7 @@ static authdb_table_info_t *register_table(str *table) info = (authdb_table_info_t*)pkg_malloc(sizeof(authdb_table_info_t) + table->len + 1); if (!info) { - LM_ERR("can't allocate pkg mem\n"); + PKG_MEM_ERROR; return NULL; }
1 year, 5 months
1
0
0
0
git:master:6f68f55c: qos: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: 6f68f55c1c654e3cb120c10eb6999d538d943ca2 URL:
https://github.com/kamailio/kamailio/commit/6f68f55c1c654e3cb120c10eb6999d5…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:20:16Z qos: convert to memory logging helper --- Modified: src/modules/qos/qos_cb.c Modified: src/modules/qos/qos_ctx_helpers.c --- Diff:
https://github.com/kamailio/kamailio/commit/6f68f55c1c654e3cb120c10eb6999d5…
Patch:
https://github.com/kamailio/kamailio/commit/6f68f55c1c654e3cb120c10eb6999d5…
--- diff --git a/src/modules/qos/qos_cb.c b/src/modules/qos/qos_cb.c index e2b0c0f9aee..6c81411d6f0 100644 --- a/src/modules/qos/qos_cb.c +++ b/src/modules/qos/qos_cb.c @@ -34,7 +34,7 @@ int init_qos_callbacks(void) { create_cbs = (struct qos_head_cbl*)shm_malloc(sizeof(struct qos_head_cbl)); if (create_cbs==0) { - LM_ERR("no more shm mem\n"); + SHM_MEM_ERROR; return -1; } create_cbs->first = 0; @@ -88,7 +88,7 @@ int register_qoscb(qos_ctx_t *qos, int types, qos_cb f, void *param ) } cb = (struct qos_callback*)shm_malloc(sizeof(struct qos_callback)); if (cb==0) { - LM_ERR("no more shm mem\n"); + SHM_MEM_ERROR; return -1; } diff --git a/src/modules/qos/qos_ctx_helpers.c b/src/modules/qos/qos_ctx_helpers.c index f36193cf6ce..25143dfdb4d 100644 --- a/src/modules/qos/qos_ctx_helpers.c +++ b/src/modules/qos/qos_ctx_helpers.c @@ -52,7 +52,7 @@ qos_ctx_t *build_new_qos_ctx(void) { if (ctx!=NULL) { memset(ctx, 0, sizeof(qos_ctx_t)); } else { - LM_ERR("No enough shared memory\n"); + SHM_MEM_ERROR; return NULL; } if (!lock_init(&ctx->lock)) { @@ -342,7 +342,7 @@ int add_pending_sdp_session(qos_ctx_t *qos_ctx, unsigned int dir, str *cseq_numb qos_sdp = (qos_sdp_t *)shm_malloc(len); LM_DBG("alloc qos_sdp: %p\n", qos_sdp); if (qos_sdp==NULL) { - LM_ERR("oom %d\n", len); + SHM_MEM_ERROR_FMT("missing %d\n", len); return -1; } else { memset(qos_sdp, 0, len);
1 year, 5 months
1
0
0
0
git:master:f7588fb8: siputils: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: f7588fb8fb804aa7585db5cb97433b69763ceb62 URL:
https://github.com/kamailio/kamailio/commit/f7588fb8fb804aa7585db5cb97433b6…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:17:56Z siputils: convert to memory logging helper --- Modified: src/modules/siputils/chargingvector.c Modified: src/modules/siputils/checks.c Modified: src/modules/siputils/contact_ops.c Modified: src/modules/siputils/options.c Modified: src/modules/siputils/rpid.c Modified: src/modules/siputils/utils.c --- Diff:
https://github.com/kamailio/kamailio/commit/f7588fb8fb804aa7585db5cb97433b6…
Patch:
https://github.com/kamailio/kamailio/commit/f7588fb8fb804aa7585db5cb97433b6…
1 year, 5 months
1
0
0
0
git:master:d5ab93a1: statsc: convert to memory logging helper, free memory in case of error
by Henning Westerholt
Module: kamailio Branch: master Commit: d5ab93a1e642aec9c842c9ffe9cb712c0f41e4c0 URL:
https://github.com/kamailio/kamailio/commit/d5ab93a1e642aec9c842c9ffe9cb712…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:08:29Z statsc: convert to memory logging helper, free memory in case of error --- Modified: src/modules/statsc/statsc_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/d5ab93a1e642aec9c842c9ffe9cb712…
Patch:
https://github.com/kamailio/kamailio/commit/d5ab93a1e642aec9c842c9ffe9cb712…
--- diff --git a/src/modules/statsc/statsc_mod.c b/src/modules/statsc/statsc_mod.c index 3b636b81fc5..92447339151 100644 --- a/src/modules/statsc/statsc_mod.c +++ b/src/modules/statsc/statsc_mod.c @@ -202,7 +202,7 @@ int statsc_nmap_add(str *sname, str *rname) + STRLEN_ROUNDUP(sname->len) + STRLEN_ROUNDUP(rname->len); sm = shm_malloc(sz); if(sm==NULL) { - LM_ERR("no more shared memory\n"); + SHM_MEM_ERROR; return -1; } memset(sm, 0, sz); @@ -241,7 +241,7 @@ int statsc_init(void) _statsc_info = shm_malloc(sizeof(statsc_info_t)); if(_statsc_info==NULL) { - LM_ERR("no more shared memory\n"); + SHM_MEM_ERROR; return -1; } memset(_statsc_info, 0, sizeof(statsc_info_t)); @@ -250,7 +250,8 @@ int statsc_init(void) sz = sizeof(statsc_nmap_t) + statsc_items * sizeof(int64_t); sm = shm_malloc(sz); if(sm==NULL) { - LM_ERR("no more shared memory\n"); + SHM_MEM_ERROR; + shm_free(_statsc_info); return -1; } memset(sm, 0, sz);
1 year, 5 months
1
0
0
0
git:master:7747f91f: stun: convert to memory logging helper
by Henning Westerholt
Module: kamailio Branch: master Commit: 7747f91f6c482a99cfab4813e3b2ad5e6e970d07 URL:
https://github.com/kamailio/kamailio/commit/7747f91f6c482a99cfab4813e3b2ad5…
Author: Pantelis Kolatsis <pk(a)gilawa.com> Committer: Henning Westerholt <hw(a)gilawa.com> Date: 2023-04-24T19:06:41Z stun: convert to memory logging helper --- Modified: src/modules/stun/kam_stun.c --- Diff:
https://github.com/kamailio/kamailio/commit/7747f91f6c482a99cfab4813e3b2ad5…
Patch:
https://github.com/kamailio/kamailio/commit/7747f91f6c482a99cfab4813e3b2ad5…
--- diff --git a/src/modules/stun/kam_stun.c b/src/modules/stun/kam_stun.c index 04f52fa2bfd..0ddbb00ed1c 100644 --- a/src/modules/stun/kam_stun.c +++ b/src/modules/stun/kam_stun.c @@ -408,7 +408,7 @@ static int stun_create_response( */ res->msg.buf.s = (char *) pkg_malloc(sizeof(char)*STUN_MSG_LEN); if (res->msg.buf.s == NULL) { - LOG(L_ERR, "ERROR: STUN: out of memory\n"); + PKG_MEM_ERROR; return FATAL_ERROR; } @@ -822,7 +822,7 @@ static struct stun_unknown_att* stun_alloc_unknown_attr(USHORT_T type) attr = (struct stun_unknown_att *) pkg_malloc(sizeof(struct stun_unknown_att)); if (attr == NULL) { - LOG(L_ERR, "ERROR: STUN: out of memory\n"); + PKG_MEM_ERROR; return NULL; }
1 year, 5 months
1
0
0
0
← Newer
1
...
14
15
16
17
18
19
20
...
27
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
Results per page:
10
25
50
100
200