Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
813609b8
Commit
813609b8
authored
Mar 29, 2016
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 30, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jscript: Use already running interpreter for Function.apply() execution.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
fa726bed
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
dispex.c
dlls/jscript/dispex.c
+1
-0
function.c
dlls/jscript/function.c
+4
-4
No files found.
dlls/jscript/dispex.c
View file @
813609b8
...
@@ -377,6 +377,7 @@ static HRESULT invoke_prop_func(jsdisp_t *This, IDispatch *jsthis, dispex_prop_t
...
@@ -377,6 +377,7 @@ static HRESULT invoke_prop_func(jsdisp_t *This, IDispatch *jsthis, dispex_prop_t
if
(
prop
->
name
||
This
->
builtin_info
->
class
!=
JSCLASS_FUNCTION
)
{
if
(
prop
->
name
||
This
->
builtin_info
->
class
!=
JSCLASS_FUNCTION
)
{
vdisp_t
vthis
;
vdisp_t
vthis
;
if
(
This
->
builtin_info
->
class
!=
JSCLASS_FUNCTION
)
flags
&=
~
DISPATCH_JSCRIPT_INTERNAL_MASK
;
flags
&=
~
DISPATCH_JSCRIPT_INTERNAL_MASK
;
if
(
jsthis
)
if
(
jsthis
)
set_disp
(
&
vthis
,
jsthis
);
set_disp
(
&
vthis
,
jsthis
);
...
...
dlls/jscript/function.c
View file @
813609b8
...
@@ -274,12 +274,12 @@ static HRESULT invoke_value_proc(script_ctx_t *ctx, FunctionInstance *function,
...
@@ -274,12 +274,12 @@ static HRESULT invoke_value_proc(script_ctx_t *ctx, FunctionInstance *function,
}
}
static
HRESULT
call_function
(
script_ctx_t
*
ctx
,
FunctionInstance
*
function
,
IDispatch
*
this_obj
,
static
HRESULT
call_function
(
script_ctx_t
*
ctx
,
FunctionInstance
*
function
,
IDispatch
*
this_obj
,
unsigned
argc
,
jsval_t
*
argv
,
jsval_t
*
r
)
unsigned
argc
,
jsval_t
*
argv
,
BOOL
caller_execs_source
,
jsval_t
*
r
)
{
{
if
(
function
->
value_proc
)
if
(
function
->
value_proc
)
return
invoke_value_proc
(
ctx
,
function
,
this_obj
,
DISPATCH_METHOD
,
argc
,
argv
,
r
);
return
invoke_value_proc
(
ctx
,
function
,
this_obj
,
DISPATCH_METHOD
,
argc
,
argv
,
r
);
return
invoke_source
(
ctx
,
function
,
this_obj
,
argc
,
argv
,
FALSE
,
FALSE
,
r
);
return
invoke_source
(
ctx
,
function
,
this_obj
,
argc
,
argv
,
FALSE
,
caller_execs_source
,
r
);
}
}
static
HRESULT
function_to_string
(
FunctionInstance
*
function
,
jsstr_t
**
ret
)
static
HRESULT
function_to_string
(
FunctionInstance
*
function
,
jsstr_t
**
ret
)
...
@@ -459,7 +459,7 @@ static HRESULT Function_apply(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, un
...
@@ -459,7 +459,7 @@ static HRESULT Function_apply(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, un
}
}
if
(
SUCCEEDED
(
hres
))
if
(
SUCCEEDED
(
hres
))
hres
=
call_function
(
ctx
,
function
,
this_obj
,
cnt
,
args
,
r
);
hres
=
call_function
(
ctx
,
function
,
this_obj
,
cnt
,
args
,
(
flags
&
DISPATCH_JSCRIPT_CALLEREXECSSOURCE
)
!=
0
,
r
);
if
(
this_obj
)
if
(
this_obj
)
IDispatch_Release
(
this_obj
);
IDispatch_Release
(
this_obj
);
...
@@ -492,7 +492,7 @@ static HRESULT Function_call(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, uns
...
@@ -492,7 +492,7 @@ static HRESULT Function_call(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, uns
cnt
=
argc
-
1
;
cnt
=
argc
-
1
;
}
}
hres
=
call_function
(
ctx
,
function
,
this_obj
,
cnt
,
argv
+
1
,
r
);
hres
=
call_function
(
ctx
,
function
,
this_obj
,
cnt
,
argv
+
1
,
FALSE
,
r
);
if
(
this_obj
)
if
(
this_obj
)
IDispatch_Release
(
this_obj
);
IDispatch_Release
(
this_obj
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment