Commit bbe5f565 authored by Justin Novosad's avatar Justin Novosad Committed by Commit Bot

Add missing null check in OffscreenCanvas::Commit

BUG=866241

Change-Id: Ic789573da753fe1e438778d777556a659fbf0ba9
Reviewed-on: https://chromium-review.googlesource.com/1147460Reviewed-by: default avatarFernando Serboncini <fserb@chromium.org>
Commit-Queue: Justin Novosad <junov@chromium.org>
Cr-Commit-Position: refs/heads/master@{#577322}
parent 36ef619d
...@@ -45,7 +45,7 @@ OffscreenCanvas::~OffscreenCanvas() = default; ...@@ -45,7 +45,7 @@ OffscreenCanvas::~OffscreenCanvas() = default;
void OffscreenCanvas::Commit(scoped_refptr<CanvasResource> canvas_resource, void OffscreenCanvas::Commit(scoped_refptr<CanvasResource> canvas_resource,
const SkIRect& damage_rect) { const SkIRect& damage_rect) {
if (!HasPlaceholderCanvas()) if (!HasPlaceholderCanvas() || !canvas_resource)
return; return;
base::TimeTicks commit_start_time = WTF::CurrentTimeTicks(); base::TimeTicks commit_start_time = WTF::CurrentTimeTicks();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment