[sr-dev] git:master:37580a25: xhttp_pi: wrap freeing and setting to null in curly braces
Daniel-Constantin Mierla
miconda at gmail.com
Tue Feb 8 08:07:06 CET 2022
Module: kamailio
Branch: master
Commit: 37580a25694d5e5b0b4c89a92d1ba2d8b77aacba
URL: https://github.com/kamailio/kamailio/commit/37580a25694d5e5b0b4c89a92d1ba2d8b77aacba
Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2022-02-08T08:06:02+01:00
xhttp_pi: wrap freeing and setting to null in curly braces
- GH #3012
---
Modified: src/modules/xhttp_pi/xhttp_pi_fnc.c
---
Diff: https://github.com/kamailio/kamailio/commit/37580a25694d5e5b0b4c89a92d1ba2d8b77aacba.diff
Patch: https://github.com/kamailio/kamailio/commit/37580a25694d5e5b0b4c89a92d1ba2d8b77aacba.patch
---
diff --git a/src/modules/xhttp_pi/xhttp_pi_fnc.c b/src/modules/xhttp_pi/xhttp_pi_fnc.c
index a11b3f40a2..96f1707649 100644
--- a/src/modules/xhttp_pi/xhttp_pi_fnc.c
+++ b/src/modules/xhttp_pi/xhttp_pi_fnc.c
@@ -2901,7 +2901,7 @@ int ph_run_pi_cmd(pi_ctx_t* ctx)
case 0:
LM_ERR("no record on clause key [%.*s]\n",
command->c_keys[0]->len, command->c_keys[0]->s);
- if(c_vals) pkg_free(c_vals); c_vals = NULL;
+ if(c_vals) { pkg_free(c_vals); c_vals = NULL; }
goto finish_page;
case 1:
LM_DBG("got [%d] rows for key [%.*s]\n",
More information about the sr-dev
mailing list