Skip to content

Commit

Permalink
Bug 1560736 - MakeCurrent after GeckoSurfaceTexture::DestroyUnused. r…
Browse files Browse the repository at this point in the history
…=snorp

Seems like GeckoSurfaceTexture::DestroyUnused can change the current
context.

Differential Revision: https://phabricator.services.mozilla.com/D36685

--HG--
extra : moz-landing-system : lando
  • Loading branch information
kdashg committed Jul 3, 2019
1 parent 043855a commit c01f565
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions gfx/layers/opengl/CompositorOGL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -786,6 +786,7 @@ void CompositorOGL::BeginFrame(const nsIntRegion& aInvalidRegion,

#ifdef MOZ_WIDGET_ANDROID
java::GeckoSurfaceTexture::DestroyUnused((int64_t)mGLContext.get());
mGLContext->MakeCurrent(); // DestroyUnused can change the current context!
#endif

// Default blend function implements "OVER"
Expand Down
1 change: 1 addition & 0 deletions gfx/webrender_bindings/RenderCompositorEGL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ bool RenderCompositorEGL::BeginFrame() {

#ifdef MOZ_WIDGET_ANDROID
java::GeckoSurfaceTexture::DestroyUnused((int64_t)gl());
gl()->MakeCurrent(); // DestroyUnused can change the current context!
#endif

return true;
Expand Down

0 comments on commit c01f565

Please sign in to comment.