- Code: Select all
[0602/192403.349:FATAL:browser_main.cc(217)] Check failed: global_request_context_->HasOneRef().
and a fatal error with a release build (I'm assuming due to the failed assert)
- Code: Select all
#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ffd6c8946e6, pid=3712, tid=8680
#
# JRE version: OpenJDK Runtime Environment (11.0.6+10) (build 11.0.6+10)
# Java VM: OpenJDK 64-Bit Server VM (11.0.6+10, mixed mode, tiered, compressed oops, g1 gc, windows-amd64)
# Problematic frame:
# C [jcef.dll+0x346e6]
#
# No core dump will be written. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# C:\...\hs_err_pid3712.log
#
# If you would like to submit a bug report, please visit:
# https://github.com/AdoptOpenJDK/openjdk-support/issues
#
I can reproduce this in the simple test by reordering the calls to dispose() and CefApp.getInstance().dispose() in the WindowAdapter. When you call dispose() before CefApp.getInstance().dispose() you will see the same problem. This only seems to be an issue on Windows. Linux seems to work without error (or perhaps isn't reporting it).
Is there a recommended way to handle this? I've tried removing the browser UI component from the container and closing the browser, but neither seem to make a difference.