summaryrefslogtreecommitdiffstats
path: root/webkit/plugins
diff options
context:
space:
mode:
authorreveman@google.com <reveman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-12 01:36:40 +0000
committerreveman@google.com <reveman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-12 01:36:40 +0000
commit3e4aabc2c524579517ec69c4cc32ec2b3297faef (patch)
treece440b5b1db5c4d9dcf14201880b7e49b71d8c17 /webkit/plugins
parentc72b3c06dd7e77ebc0dc854167c8c9b9d1afcc58 (diff)
downloadchromium_src-3e4aabc2c524579517ec69c4cc32ec2b3297faef.zip
chromium_src-3e4aabc2c524579517ec69c4cc32ec2b3297faef.tar.gz
chromium_src-3e4aabc2c524579517ec69c4cc32ec2b3297faef.tar.bz2
Make sure webkit compositor is not using ppapi backing texture ID after it has been destroyed.
Set backing texture ID to 0 before destroying ppapi context and finish parent context before texture ID is freed. BUG=chromium-os:16976 TEST=manual Review URL: http://codereview.chromium.org/7327011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92095 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/plugins')
-rw-r--r--webkit/plugins/ppapi/ppb_surface_3d_impl.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/webkit/plugins/ppapi/ppb_surface_3d_impl.cc b/webkit/plugins/ppapi/ppb_surface_3d_impl.cc
index 5cab3f6d0..f1c9eef 100644
--- a/webkit/plugins/ppapi/ppb_surface_3d_impl.cc
+++ b/webkit/plugins/ppapi/ppb_surface_3d_impl.cc
@@ -93,6 +93,9 @@ bool PPB_Surface3D_Impl::BindToContext(PPB_Context3D_Impl* context) {
if (context == context_)
return true;
+ if (!context && bound_to_instance_)
+ instance()->BindGraphics(instance()->pp_instance(), 0);
+
// Unbind from the current context.
if (context_ && context_->platform_context())
context_->platform_context()->SetSwapBuffersCallback(NULL);