Skip to content

Commit

Permalink
Return after callback on failure in GrRenderTargetContext::asyncReadP…
Browse files Browse the repository at this point in the history
…ixels

Bug: chromium:1048251
Change-Id: I9c18e55fd791adbf446aa776de297b857af22b64
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/269237
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
(cherry picked from commit 4bb5026)
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270178
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
  • Loading branch information
bsalomon committed Feb 11, 2020
1 parent 3e98c0e commit 84cb5d3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/gpu/GrRenderTargetContext.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1875,6 +1875,7 @@ void GrRenderTargetContext::asyncReadPixels(const SkIRect& rect, SkColorType col

if (!this->readPixels(ii, pm.writable_addr(), pm.rowBytes(), {rect.fLeft, rect.fTop})) {
callback(context, nullptr);
return;
}
callback(context, std::move(result));
return;
Expand Down

0 comments on commit 84cb5d3

Please sign in to comment.