Module: wine Branch: master Commit: b866c7f5e90b9c1db182e1ab94459df3524e8a4b URL: http://source.winehq.org/git/wine.git/?a=commit;h=b866c7f5e90b9c1db182e1ab94...
Author: Jacek Caban jacek@codeweavers.com Date: Wed Apr 25 11:26:12 2012 +0200
jscript: Make parser a temporary compiler object.
---
dlls/jscript/compile.c | 6 +----- dlls/jscript/engine.h | 2 -- 2 files changed, 1 insertions(+), 7 deletions(-)
diff --git a/dlls/jscript/compile.c b/dlls/jscript/compile.c index 6afef2c..796fb7b 100644 --- a/dlls/jscript/compile.c +++ b/dlls/jscript/compile.c @@ -1732,9 +1732,6 @@ void release_bytecode(bytecode_t *code) if(--code->ref) return;
- if(code->parser) - parser_release(code->parser); - for(i=0; i < code->bstr_cnt; i++) SysFreeString(code->bstr_pool[i]);
@@ -1878,9 +1875,8 @@ HRESULT compile_script(script_ctx_t *ctx, const WCHAR *code, const WCHAR *delimi return hres; }
- compiler.code->parser = compiler.parser; - hres = compile_function(&compiler, compiler.parser->source, NULL, from_eval, &compiler.code->global_code); + parser_release(compiler.parser); if(FAILED(hres)) { release_bytecode(compiler.code); return hres; diff --git a/dlls/jscript/engine.h b/dlls/jscript/engine.h index c57b89e..20f3c45 100644 --- a/dlls/jscript/engine.h +++ b/dlls/jscript/engine.h @@ -197,8 +197,6 @@ typedef struct _bytecode_t { unsigned bstr_pool_size; unsigned bstr_cnt;
- parser_ctx_t *parser; - struct _bytecode_t *next; } bytecode_t;