jscript: Use the proper variable_obj for bytecodes with named items.
Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com> Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
4ff594e885
commit
b7ddcbbc18
|
@ -3030,6 +3030,8 @@ HRESULT exec_source(script_ctx_t *ctx, DWORD flags, bytecode_t *bytecode, functi
|
|||
}else if(!(flags & (EXEC_GLOBAL | EXEC_EVAL))) {
|
||||
hres = create_dispex(ctx, NULL, NULL, &variable_obj);
|
||||
if(FAILED(hres)) return hres;
|
||||
}else if(bytecode->named_item) {
|
||||
variable_obj = jsdisp_addref(bytecode->named_item->script_obj);
|
||||
}else {
|
||||
variable_obj = jsdisp_addref(ctx->global);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue