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

Unified Diff: Source/core/rendering/svg/RenderSVGResourceFilter.cpp

Issue 562543004: Check If ImageBuffer is allocated before proceeding. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 3 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 | Source/platform/graphics/GraphicsContextTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/svg/RenderSVGResourceFilter.cpp
diff --git a/Source/core/rendering/svg/RenderSVGResourceFilter.cpp b/Source/core/rendering/svg/RenderSVGResourceFilter.cpp
index 7ae178c9090d0a7a7e5fea86d97c77253e7ca14a..7ce9edaadd02a441e1f7379b26c5103a5e7e353f 100644
--- a/Source/core/rendering/svg/RenderSVGResourceFilter.cpp
+++ b/Source/core/rendering/svg/RenderSVGResourceFilter.cpp
@@ -131,6 +131,8 @@ static bool createImageBuffer(const Filter* filter, OwnPtr<ImageBuffer>& imageBu
if (!surface->isValid())
return false;
OwnPtr<ImageBuffer> image = ImageBuffer::create(surface.release());
+ if (!image)
Stephen White 2014/09/12 19:12:20 This change seems harmless, but note that this cod
sivag 2014/09/12 20:52:06 Thanks Stephen. Please let me know if some changes
+ return false;
GraphicsContext* imageContext = image->context();
ASSERT(imageContext);
« no previous file with comments | « no previous file | Source/platform/graphics/GraphicsContextTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698