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

Unified Diff: content/browser/compositor/surface_utils.cc

Issue 2094803005: Fix PrepareTextureCopyOutputResult to avoid ScopedCallbackRunner. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_closure_runner
Patch Set: . Created 4 years, 5 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
Index: content/browser/compositor/surface_utils.cc
diff --git a/content/browser/compositor/surface_utils.cc b/content/browser/compositor/surface_utils.cc
index e0e49162781b9b649f38fb25a2d5e09d765082b5..4cbd80dfaba4f2b39b2b912799351c9e32a10d41 100644
--- a/content/browser/compositor/surface_utils.cc
+++ b/content/browser/compositor/surface_utils.cc
@@ -76,7 +76,7 @@ void PrepareTextureCopyOutputResult(
if (!bitmap->tryAllocPixels(SkImageInfo::Make(
dst_size_in_pixel.width(), dst_size_in_pixel.height(), color_type,
kOpaque_SkAlphaType))) {
- scoped_callback_runner.Reset(base::Bind(
+ scoped_callback_runner.ReplaceClosure(base::Bind(
callback, SkBitmap(), content::READBACK_BITMAP_ALLOCATION_FAILURE));
return;
}

Powered by Google App Engine
This is Rietveld 408576698