Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit a29ab4b

Browse files
Detach the newly created EGL context from the main thread in the embedder unit tests (#24908)
The EGL context will be used by other threads during test execution, and it should not be active on multiple threads at the same time. This was not noticed previously because SwiftShader was not checking for this, but other EGL implementations may enforce this constraint.
1 parent a560c26 commit a29ab4b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

shell/platform/embedder/tests/embedder_test_context_gl.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ void EmbedderTestContextGL::SetupCompositor() {
115115
<< "Set up the GL surface before setting up a compositor.";
116116
compositor_ = std::make_unique<EmbedderTestCompositorGL>(
117117
gl_surface_->GetSurfaceSize(), gl_surface_->GetGrContext());
118+
GLClearCurrent();
118119
}
119120

120121
} // namespace testing

0 commit comments

Comments
 (0)