Module: wine Branch: master Commit: d39e3d8762dcce81434114aef02142866ad5ddb5 URL: https://source.winehq.org/git/wine.git/?a=commit;h=d39e3d8762dcce81434114aef...
Author: Hans Leidekker hans@codeweavers.com Date: Tue Oct 27 11:31:40 2020 +0100
jscript: Fix allocation size in BindFunction_call.
Signed-off-by: Hans Leidekker hans@codeweavers.com Signed-off-by: Jacek Caban jacek@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/jscript/function.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/jscript/function.c b/dlls/jscript/function.c index e43d19464bb..6361eefc677 100644 --- a/dlls/jscript/function.c +++ b/dlls/jscript/function.c @@ -836,7 +836,7 @@ static HRESULT BindFunction_call(script_ctx_t *ctx, FunctionInstance *func, IDis
call_argc = function->argc + argc; if(call_argc) { - call_args = heap_alloc(function->argc * sizeof(*function->args)); + call_args = heap_alloc(call_argc * sizeof(*call_args)); if(!call_args) return E_OUTOFMEMORY;