From: Gabriel Ivăncescu gabrielopcode@gmail.com
Signed-off-by: Gabriel Ivăncescu gabrielopcode@gmail.com ---
Native is pretty weird. It actually seems to return "Permission Denied" (0x800a0046) when called from javascript, but works fine when called from C? We do have a test in events.c/test_document_close() that assumes it works, so for now I added this as todo_wine here in navigation.js. If you'd prefer it the other way around, I can make the old test todo_wine and "fix" the new one. --- dlls/mshtml/htmldoc.c | 2 +- dlls/mshtml/tests/navigation.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/mshtml/htmldoc.c b/dlls/mshtml/htmldoc.c index e37f04fee0b..3f844fddf8d 100644 --- a/dlls/mshtml/htmldoc.c +++ b/dlls/mshtml/htmldoc.c @@ -905,7 +905,7 @@ static HRESULT WINAPI HTMLDocument_get_readyState(IHTMLDocument2 *iface, BSTR *p if(!p) return E_POINTER;
- return get_readystate_string(This->outer_window ? This->outer_window->readystate : 0, p); + return get_readystate_string(This->window && This->window->base.outer_window ? This->window->base.outer_window->readystate : 0, p); }
static HRESULT WINAPI HTMLDocument_get_frames(IHTMLDocument2 *iface, IHTMLFramesCollection2 **p) diff --git a/dlls/mshtml/tests/navigation.js b/dlls/mshtml/tests/navigation.js index 402d933a54a..84a0bbdcb5d 100644 --- a/dlls/mshtml/tests/navigation.js +++ b/dlls/mshtml/tests/navigation.js @@ -119,6 +119,7 @@ function detached_iframe_doc() { expect_exception(function() { origDoc.onclick; }, true); expect_exception(function() { origDoc.toString; }, true); expect_exception(function() { origDoc.toString(); }, true); + expect_exception(function() { origDoc.readyState; }, true); expect_exception(function() { origDoc.URL; }); expect_exception(function() { origDoc.URL = "blank.html"; });