diff options
author | Ilia Alshanetsky <iliaa@php.net> | 2003-11-29 18:22:44 +0000 |
---|---|---|
committer | Ilia Alshanetsky <iliaa@php.net> | 2003-11-29 18:22:44 +0000 |
commit | 9e195d1040efdc7d14a94d7be9b01c65c8d24b61 (patch) | |
tree | d5189b0b79ac403f932600bb73bbafa64bf17bae /ext/tokenizer/tokenizer.c | |
parent | fd7b38d7528a77b992b1c1c5fbc2706f02d0f58f (diff) | |
download | php-git-9e195d1040efdc7d14a94d7be9b01c65c8d24b61.tar.gz |
Fixed a memory leak when tokenizing scripts with heredoc.
Diffstat (limited to 'ext/tokenizer/tokenizer.c')
-rw-r--r-- | ext/tokenizer/tokenizer.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/tokenizer/tokenizer.c b/ext/tokenizer/tokenizer.c index 3414543d8f..5c7346c4ba 100644 --- a/ext/tokenizer/tokenizer.c +++ b/ext/tokenizer/tokenizer.c @@ -369,6 +369,9 @@ static void tokenize(zval *return_value TSRMLS_DC) if (destroy && Z_TYPE(token) != IS_NULL) { zval_dtor(&token); } + if (token_type == T_END_HEREDOC) { + efree(Z_STRVAL(token)); + } ZVAL_NULL(&token); } } |