mirror of
https://github.com/reactos/wine.git
synced 2024-11-26 05:00:30 +00:00
jscript: Fixed compare function check in Array.sort (Coverity).
This commit is contained in:
parent
ec35d3ab38
commit
0c20b1d0a1
@ -433,8 +433,9 @@ static HRESULT Array_sort(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS
|
||||
|
||||
|
||||
cmp_func = iface_to_jsdisp((IUnknown*)V_DISPATCH(arg));
|
||||
if(!is_class(cmp_func, JSCLASS_FUNCTION)) {
|
||||
if(!cmp_func || !is_class(cmp_func, JSCLASS_FUNCTION)) {
|
||||
WARN("cmp_func is not a function\n");
|
||||
if(cmp_func)
|
||||
jsdisp_release(cmp_func);
|
||||
return E_FAIL;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user