summaryrefslogtreecommitdiff
path: root/sapi/phpdbg/phpdbg_cmd.c
diff options
context:
space:
mode:
authorBob Weinand <bobwei9@hotmail.com>2015-08-03 20:27:46 +0200
committerBob Weinand <bobwei9@hotmail.com>2015-08-03 20:27:46 +0200
commitb5e16cebda52b25f651b97c9b9da830ee7e46138 (patch)
tree6560068aa8fdc51aa72754d1e5e3b11c5253adab /sapi/phpdbg/phpdbg_cmd.c
parent34596a3dddb407fc36af7cdf9da55253210da5e1 (diff)
downloadphp-git-b5e16cebda52b25f651b97c9b9da830ee7e46138.tar.gz
Fix a few valgrind errors in phpdbg
Diffstat (limited to 'sapi/phpdbg/phpdbg_cmd.c')
-rw-r--r--sapi/phpdbg/phpdbg_cmd.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/sapi/phpdbg/phpdbg_cmd.c b/sapi/phpdbg/phpdbg_cmd.c
index f01f765045..71a27f5dec 100644
--- a/sapi/phpdbg/phpdbg_cmd.c
+++ b/sapi/phpdbg/phpdbg_cmd.c
@@ -385,23 +385,27 @@ PHPDBG_API void phpdbg_stack_free(phpdbg_param_t *stack) {
switch (remove->type) {
case NUMERIC_METHOD_PARAM:
case METHOD_PARAM:
- if (remove->method.class)
- free(remove->method.class);
- if (remove->method.name)
- free(remove->method.name);
+ if (remove->method.class) {
+ efree(remove->method.class);
+ }
+ if (remove->method.name) {
+ efree(remove->method.name);
+ }
break;
case NUMERIC_FUNCTION_PARAM:
case STR_PARAM:
case OP_PARAM:
- if (remove->str)
- free(remove->str);
+ if (remove->str) {
+ efree(remove->str);
+ }
break;
case NUMERIC_FILE_PARAM:
case FILE_PARAM:
- if (remove->file.name)
- free(remove->file.name);
+ if (remove->file.name) {
+ efree(remove->file.name);
+ }
break;
default: {