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

Unified Diff: chrome/browser/ui/webui/chromeos/image_source.cc

Issue 2517053004: Use base::RefCountedBytes in user_manager::UserImage (Closed)
Patch Set: Created 4 years, 1 month 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: chrome/browser/ui/webui/chromeos/image_source.cc
diff --git a/chrome/browser/ui/webui/chromeos/image_source.cc b/chrome/browser/ui/webui/chromeos/image_source.cc
index e6af8a9c55003a844928e0f17953ce6a91c9f0a4..1e99da9b8b3c769833709cdc0473cf1a240ce6a6 100644
--- a/chrome/browser/ui/webui/chromeos/image_source.cc
+++ b/chrome/browser/ui/webui/chromeos/image_source.cc
@@ -38,9 +38,8 @@ void ImageLoaded(
std::unique_ptr<user_manager::UserImage> user_image) {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
- // TODO(crbug.com/593251): Remove the data copy.
if (user_image->has_image_bytes())
- got_data_callback.Run(new base::RefCountedBytes(user_image->image_bytes()));
+ got_data_callback.Run(user_image->image_bytes());
else
got_data_callback.Run(NULL);
achuithb 2016/11/22 21:16:54 nullptr?
satorux1 2016/11/24 02:13:40 Fixed here and elsewhere in the file
}

Powered by Google App Engine
This is Rietveld 408576698