Jacek Caban : mshtml: Fixed error handling in IHTMLFormElement:: item in IE9+ mode.
Alexandre Julliard
julliard at winehq.org
Thu Feb 8 15:33:09 CST 2018
Module: wine
Branch: master
Commit: 7da84dfe97147fa2eb2e9b582975eec84fa4cc16
URL: https://source.winehq.org/git/wine.git/?a=commit;h=7da84dfe97147fa2eb2e9b582975eec84fa4cc16
Author: Jacek Caban <jacek at codeweavers.com>
Date: Thu Feb 8 20:53:48 2018 +0100
mshtml: Fixed error handling in IHTMLFormElement::item in IE9+ mode.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/mshtml/htmlform.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/mshtml/htmlform.c b/dlls/mshtml/htmlform.c
index 2957ad1..51adc20 100644
--- a/dlls/mshtml/htmlform.c
+++ b/dlls/mshtml/htmlform.c
@@ -540,8 +540,11 @@ static HRESULT WINAPI HTMLFormElement_item(IHTMLFormElement *iface, VARIANT name
*pdisp = NULL;
if(V_VT(&name) == VT_I4) {
- if(V_I4(&name) < 0)
- return E_INVALIDARG;
+ if(V_I4(&name) < 0) {
+ *pdisp = NULL;
+ return dispex_compat_mode(&This->element.node.event_target.dispex) >= COMPAT_MODE_IE9
+ ? S_OK : E_INVALIDARG;
+ }
return htmlform_item(This, V_I4(&name), pdisp);
}
More information about the wine-cvs
mailing list