jscript: Propagate compiler error location.
Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
27e4881c68
commit
ed22d71fd2
|
@ -2519,8 +2519,11 @@ HRESULT compile_script(script_ctx_t *ctx, const WCHAR *code, UINT64 source_conte
|
|||
heap_pool_free(&compiler.heap);
|
||||
parser_release(compiler.parser);
|
||||
if(FAILED(hres)) {
|
||||
if(hres != DISP_E_EXCEPTION)
|
||||
throw_error(ctx, hres, NULL);
|
||||
set_error_location(ctx->ei, compiler.code, compiler.loc, IDS_COMPILATION_ERROR);
|
||||
release_bytecode(compiler.code);
|
||||
return hres;
|
||||
return DISP_E_EXCEPTION;
|
||||
}
|
||||
|
||||
*ret = compiler.code;
|
||||
|
|
Loading…
Reference in New Issue