Module: kamailio
Branch: master
Commit: 1fdc4be9541b1363081fd769ab9d863afe27a961
URL:
https://github.com/kamailio/kamailio/commit/1fdc4be9541b1363081fd769ab9d863…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2018-12-28T15:47:19+01:00
app_jsdt: use mem error macros
---
Modified: src/modules/app_jsdt/app_jsdt_api.c
---
Diff:
https://github.com/kamailio/kamailio/commit/1fdc4be9541b1363081fd769ab9d863…
Patch:
https://github.com/kamailio/kamailio/commit/1fdc4be9541b1363081fd769ab9d863…
---
diff --git a/src/modules/app_jsdt/app_jsdt_api.c b/src/modules/app_jsdt/app_jsdt_api.c
index 907433573b..ee25fd5379 100644
--- a/src/modules/app_jsdt/app_jsdt_api.c
+++ b/src/modules/app_jsdt/app_jsdt_api.c
@@ -604,7 +604,7 @@ static int jsdt_sr_modf (duk_context *J)
if(jsdtv[i]!=NULL) {
argv[i] = (char*)pkg_malloc(strlen(jsdtv[i])+1);
if(argv[i]==NULL) {
- LM_ERR("no more pkg\n");
+ PKG_MEM_ERROR;
goto error;
}
strcpy(argv[i], jsdtv[i]);
@@ -758,7 +758,7 @@ int jsdt_sr_init_mod(void)
if(_sr_jsdt_reload_version == NULL) {
_sr_jsdt_reload_version = (int*)shm_malloc(sizeof(int));
if(_sr_jsdt_reload_version == NULL) {
- LM_ERR("failed to allocated reload version\n");
+ SHM_MEM_ERROR;
return -1;
}
*_sr_jsdt_reload_version = 0;