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

Unified Diff: cc/playback/display_list_raster_source.cc

Issue 1633203003: cc: Fix nullptr dereference when capturing skps. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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 | « cc/playback/display_list_raster_source.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/playback/display_list_raster_source.cc
diff --git a/cc/playback/display_list_raster_source.cc b/cc/playback/display_list_raster_source.cc
index 3f740af4a722dd9a3ad9f2f0cb79fc5c03d0087f..38bc5e86138b6228e37195f554e9a4d9966c435c 100644
--- a/cc/playback/display_list_raster_source.cc
+++ b/cc/playback/display_list_raster_source.cc
@@ -387,8 +387,11 @@ skia::RefPtr<SkPicture> DisplayListRasterSource::GetFlattenedPicture() {
SkPictureRecorder recorder;
SkCanvas* canvas = recorder.beginRecording(display_list_rect.width(),
display_list_rect.height());
- if (!display_list_rect.IsEmpty())
- PlaybackToCanvas(canvas, display_list_rect, display_list_rect, 1.0);
+ if (!display_list_rect.IsEmpty()) {
+ PrepareForPlaybackToCanvas(canvas, display_list_rect, display_list_rect,
+ 1.f);
+ RasterCommon(canvas, nullptr, display_list_rect, display_list_rect, 1.f);
+ }
skia::RefPtr<SkPicture> picture =
skia::AdoptRef(recorder.endRecordingAsPicture());
« no previous file with comments | « cc/playback/display_list_raster_source.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698