diff options
author | Bob Weinand <bobwei9@hotmail.com> | 2015-08-03 20:27:46 +0200 |
---|---|---|
committer | Bob Weinand <bobwei9@hotmail.com> | 2015-08-03 20:27:46 +0200 |
commit | b5e16cebda52b25f651b97c9b9da830ee7e46138 (patch) | |
tree | 6560068aa8fdc51aa72754d1e5e3b11c5253adab /sapi/phpdbg/phpdbg_cmd.c | |
parent | 34596a3dddb407fc36af7cdf9da55253210da5e1 (diff) | |
download | php-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.c | 20 |
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: { |