Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1114)

Unified Diff: content/plugin/webplugin_proxy.cc

Issue 9460006: check for null-device before using the windowless canvas (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/plugin/webplugin_proxy.cc
===================================================================
--- content/plugin/webplugin_proxy.cc (revision 123470)
+++ content/plugin/webplugin_proxy.cc (working copy)
@@ -339,7 +339,7 @@
if (!windowless_context())
return;
#else
- if (!windowless_canvas())
+ if (!windowless_canvas() || !windowless_canvas()->getDevice())
return;
#endif
@@ -390,7 +390,7 @@
windowless_canvas()->clipRect(sk_rect);
// Setup the background.
- if (background_canvas_.get()) {
+ if (background_canvas_.get() && background_canvas_.get()->getDevice()) {
// When a background canvas is given, we're in transparent mode. This means
// the plugin wants to have the image of the page in the canvas it's drawing
// into (which is windowless_canvases_) so it can do blending. So we copy
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698