[WinCairo] WebCore::PlatformDisplay::terminateEGLDisplay causes a crash in libGLESv2.dll while processing atexit Repro steps: 1) Start MiniBrowser 2) Close MiniBrowser 3) It crashes Message box: > Exception thrown at 0x00007FF89FAB7930 (ntdll.dll) in MiniBrowser.exe: 0xC0000005: Access violation reading location 0x0000000000000010. > > If there is a handler for this exception, the program may be safely continued. Callstack: > ntdll.dll!00007ff89fab7930() Unknown > libGLESv2.dll!_malloc_base(unsigned __int64 size) Line 34 C++ > [External Code] > libGLESv2.dll!`anonymous namespace'::AllocateCurrent() Line 41 C++ > libGLESv2.dll!`anonymous namespace'::GetCurrentData() Line 70 C++ > libGLESv2.dll!gl::GetGlobalContext() Line 124 C++ > libGLESv2.dll!gl::GetValidGlobalContext() Line 131 C++ > libGLESv2.dll!gl::BindFramebuffer(unsigned int target, unsigned int framebuffer) Line 160 C++ > libGLESv2.dll!glBindFramebuffer(unsigned int target, unsigned int framebuffer) Line 42 C++ > WebKit.dll!glBindFramebuffer(unsigned int target, unsigned int framebuffer) Line 33 C++ > WebKit.dll!WebCore::GLContextEGL::~GLContextEGL() Line 243 C++ > [External Code] > WebKit.dll!WebCore::PlatformDisplay::terminateEGLDisplay() Line 233 C++ > WebKit.dll!WebCore::PlatformDisplay::initializeEGLDisplay::__l15::<lambda>() Line 225 C++ > WebKit.dll!void <lambda>(void)::<lambda_invoker_cdecl>() Line 226 C++ > [External Code] > MiniBrowser.exe!exit_or_terminate_process(const unsigned int return_code) Line 129 C++ > MiniBrowser.exe!common_exit(const int return_code, const _crt_exit_cleanup_mode cleanup_mode, const _crt_exit_return_mode return_mode) Line 265 C++ > [External Code] The atexit has been introduced in Bug 157973. PlatformDisplay.cpp is not used by AppleWin port.
Created attachment 305955 [details] Patch
Comment on attachment 305955 [details] Patch Clearing flags on attachment: 305955 Committed r214688: <http://trac.webkit.org/changeset/214688>
All reviewed patches have been landed. Closing bug.
r185411 (Bug 145832) fixed the same issue once. But, r201595 (Bug 157973) removed the code.