R
RamiAbuGhazaleh
Guest
Hi.
An unhandled exception occurs in jscript9.dll in Windows Server 2016 when using MFC's CDHtmlDialog, after installing Microsoft update KB4507460.
I've attached a reproducible example here.
Windows Server 2016 (64-bit) Version 1607 (OS Build 14393.3085)
Visual Studio 2017 15.9.14
jscript9.dll v11.0.14393.3085
Steps to reproduce:
1. Download and unzip HtmlBrowser.zip.
2. Open HtmlBrowser.sln in Visual Studio 2017.
3. Select the "Debug | x64" solution configuration.
4. Start debugging the HtmlBrowser project.
Notice a similar exception as follows:
Exception thrown at 0x00007FFCFB1D4C48 in HtmlBrowser.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x0000008C78FB9EE0.
Call Stack:
[External Code]
jscript9.dll!Js::JavascriptExceptionOperators::ThrowExceptionObjectInternal() Unknown
jscript9.dll!Js::JavascriptExceptionOperators::ThrowExceptionObject(class Js::JavascriptExceptionObject *,class Js::ScriptContext *,bool,void *) Unknown
jscript9.dll!Js::JavascriptExceptionOperators::Throw() Unknown
jscript9.dll!CJavascriptOperations::ThrowException() Unknown
mshtml.dll!CFastDOM::ThrowDOMError() Unknown
mshtml.dll!CFastDOM::CElement::Trampoline_querySelectorAll(void *,struct CallInfo,...) Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptExternalFunction::ExternalFunctionThunk() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10e73() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_CallCommon<struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> >(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> const *,class Js::RecyclableObject *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_TryCatch() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_TryFinally() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10eb3() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10ec3() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_CallCommon<struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> >(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> const *,class Js::RecyclableObject *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10efb() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_CallCommon<struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI> >(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI> const *,class Js::RecyclableObject *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_ProfiledReturnTypeCallI<struct Js::OpLayoutCallI>(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI> const *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10fbb() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10fc3() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::JavascriptFunction::CallRootFunctionInternal() Unknown
jscript9.dll!Js::JavascriptFunction::CallRootFunction() Unknown
jscript9.dll!ScriptSite::CallRootFunction() Unknown
jscript9.dll!ScriptSite::Execute() Unknown
jscript9.dll!ScriptEngine::ExecutePendingScripts() Unknown
jscript9.dll!ScriptEngine:arseScriptTextCore() Unknown
jscript9.dll!ScriptEngine:arseScriptText() Unknown
mshtml.dll!CActiveScriptHolder:arseScriptText() Unknown
mshtml.dll!CJScript9Holder:arseScriptText() Unknown
mshtml.dll!CScriptCollection:arseScriptText() Unknown
mshtml.dll!CScriptData::CommitCode() Unknown
mshtml.dll!CScriptData::Execute() Unknown
mshtml.dll!CHtmScriptParseCtx::Execute() Unknown
mshtml.dll!CHtmParseBase::Execute() Unknown
mshtml.dll!CHtmPost::Broadcast() Unknown
mshtml.dll!CHtmPost::Exec() Unknown
mshtml.dll!CHtmPost::Run() Unknown
mshtml.dll!PostManExecute() Unknown
mshtml.dll!CPostManager:ostManOnTimer() Unknown
mshtml.dll!GlobalWndOnMethodCall(void) Unknown
mshtml.dll!GlobalWndProc() Unknown
user32.dll!UserCallWinProcCheckWow() Unknown
user32.dll!CallWindowProcW() Unknown
> mfc140ud.dll!_AfxActivationWndProc(HWND__ * hWnd, unsigned int nMsg, unsigned __int64 wParam, __int64 lParam) Line 478 C++
user32.dll!UserCallWinProcCheckWow() Unknown
user32.dll!DispatchMessageWorker() Unknown
mfc140ud.dll!AfxInternalPumpMessage() Line 183 C++
mfc140ud.dll!CWinThread:umpMessage() Line 900 C++
mfc140ud.dll!AfxPumpMessage() Line 190 C++
mfc140ud.dll!CWnd::RunModalLoop(unsigned long dwFlags) Line 4661 C++
mfc140ud.dll!CWnd::CreateRunDlgIndirect(const DLGTEMPLATE * lpDialogTemplate, CWnd * pParentWnd, HINSTANCE__ * hInst) Line 470 C++
mfc140ud.dll!CDialog:oModal() Line 633 C++
HtmlBrowser.exe!CHtmlBrowserApp::InitInstance() Line 73 C++
[External Code]
HtmlBrowser.exe!wWinMain(HINSTANCE__ * hInstance, HINSTANCE__ * hPrevInstance, wchar_t * lpCmdLine, int nCmdShow) Line 26 C++
[External Code]
I'm also wondering how I can prevent the JavaScript error from crashing the desktop application?
Thank you.
Continue reading...
An unhandled exception occurs in jscript9.dll in Windows Server 2016 when using MFC's CDHtmlDialog, after installing Microsoft update KB4507460.
I've attached a reproducible example here.
Windows Server 2016 (64-bit) Version 1607 (OS Build 14393.3085)
Visual Studio 2017 15.9.14
jscript9.dll v11.0.14393.3085
Steps to reproduce:
1. Download and unzip HtmlBrowser.zip.
2. Open HtmlBrowser.sln in Visual Studio 2017.
3. Select the "Debug | x64" solution configuration.
4. Start debugging the HtmlBrowser project.
Notice a similar exception as follows:
Exception thrown at 0x00007FFCFB1D4C48 in HtmlBrowser.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x0000008C78FB9EE0.
Call Stack:
[External Code]
jscript9.dll!Js::JavascriptExceptionOperators::ThrowExceptionObjectInternal() Unknown
jscript9.dll!Js::JavascriptExceptionOperators::ThrowExceptionObject(class Js::JavascriptExceptionObject *,class Js::ScriptContext *,bool,void *) Unknown
jscript9.dll!Js::JavascriptExceptionOperators::Throw() Unknown
jscript9.dll!CJavascriptOperations::ThrowException() Unknown
mshtml.dll!CFastDOM::ThrowDOMError() Unknown
mshtml.dll!CFastDOM::CElement::Trampoline_querySelectorAll(void *,struct CallInfo,...) Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptExternalFunction::ExternalFunctionThunk() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10e73() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_CallCommon<struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> >(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> const *,class Js::RecyclableObject *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_TryCatch() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_TryFinally() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10eb3() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10ec3() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_CallCommon<struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> >(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI_OneByte> const *,class Js::RecyclableObject *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10efb() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_CallCommon<struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI> >(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI> const *,class Js::RecyclableObject *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame::OP_ProfiledReturnTypeCallI<struct Js::OpLayoutCallI>(struct Js::OpLayoutDynamicProfile<struct Js::OpLayoutCallI> const *,unsigned int) Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10fbb() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::InterpreterStackFrame:rocess(void) Unknown
jscript9.dll!Js::InterpreterStackFrame::InterpreterThunk<1>(class Js::JavascriptCallStackLayout *) Unknown
000001b9a8d10fc3() Unknown
jscript9.dll!amd64_CallFunction() Unknown
jscript9.dll!Js::JavascriptFunction::CallFunction<1>() Unknown
jscript9.dll!Js::JavascriptFunction::CallRootFunctionInternal() Unknown
jscript9.dll!Js::JavascriptFunction::CallRootFunction() Unknown
jscript9.dll!ScriptSite::CallRootFunction() Unknown
jscript9.dll!ScriptSite::Execute() Unknown
jscript9.dll!ScriptEngine::ExecutePendingScripts() Unknown
jscript9.dll!ScriptEngine:arseScriptTextCore() Unknown
jscript9.dll!ScriptEngine:arseScriptText() Unknown
mshtml.dll!CActiveScriptHolder:arseScriptText() Unknown
mshtml.dll!CJScript9Holder:arseScriptText() Unknown
mshtml.dll!CScriptCollection:arseScriptText() Unknown
mshtml.dll!CScriptData::CommitCode() Unknown
mshtml.dll!CScriptData::Execute() Unknown
mshtml.dll!CHtmScriptParseCtx::Execute() Unknown
mshtml.dll!CHtmParseBase::Execute() Unknown
mshtml.dll!CHtmPost::Broadcast() Unknown
mshtml.dll!CHtmPost::Exec() Unknown
mshtml.dll!CHtmPost::Run() Unknown
mshtml.dll!PostManExecute() Unknown
mshtml.dll!CPostManager:ostManOnTimer() Unknown
mshtml.dll!GlobalWndOnMethodCall(void) Unknown
mshtml.dll!GlobalWndProc() Unknown
user32.dll!UserCallWinProcCheckWow() Unknown
user32.dll!CallWindowProcW() Unknown
> mfc140ud.dll!_AfxActivationWndProc(HWND__ * hWnd, unsigned int nMsg, unsigned __int64 wParam, __int64 lParam) Line 478 C++
user32.dll!UserCallWinProcCheckWow() Unknown
user32.dll!DispatchMessageWorker() Unknown
mfc140ud.dll!AfxInternalPumpMessage() Line 183 C++
mfc140ud.dll!CWinThread:umpMessage() Line 900 C++
mfc140ud.dll!AfxPumpMessage() Line 190 C++
mfc140ud.dll!CWnd::RunModalLoop(unsigned long dwFlags) Line 4661 C++
mfc140ud.dll!CWnd::CreateRunDlgIndirect(const DLGTEMPLATE * lpDialogTemplate, CWnd * pParentWnd, HINSTANCE__ * hInst) Line 470 C++
mfc140ud.dll!CDialog:oModal() Line 633 C++
HtmlBrowser.exe!CHtmlBrowserApp::InitInstance() Line 73 C++
[External Code]
HtmlBrowser.exe!wWinMain(HINSTANCE__ * hInstance, HINSTANCE__ * hPrevInstance, wchar_t * lpCmdLine, int nCmdShow) Line 26 C++
[External Code]
I'm also wondering how I can prevent the JavaScript error from crashing the desktop application?
Thank you.
Continue reading...