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

Unified Diff: Source/modules/imagebitmap/ImageBitmapFactories.cpp

Issue 244243002: Pass SharedBuffer by reference to DeferredImageDecoder::setData() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 8 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: Source/modules/imagebitmap/ImageBitmapFactories.cpp
diff --git a/Source/modules/imagebitmap/ImageBitmapFactories.cpp b/Source/modules/imagebitmap/ImageBitmapFactories.cpp
index 3e6429ffaed1745d1a38c630e9490dc2729c6e53..42411e66fe4670e475081e125f59145c066205dd 100644
--- a/Source/modules/imagebitmap/ImageBitmapFactories.cpp
+++ b/Source/modules/imagebitmap/ImageBitmapFactories.cpp
@@ -301,7 +301,7 @@ void ImageBitmapFactories::ImageBitmapLoader::didFinishLoading()
RefPtr<SharedBuffer> sharedBuffer = SharedBuffer::create((char*)m_loader.arrayBufferResult()->data(), m_loader.arrayBufferResult()->byteLength());
OwnPtr<ImageSource> source = adoptPtr(new ImageSource());
- source->setData(sharedBuffer.get(), true);
+ source->setData(*sharedBuffer, true);
RefPtr<NativeImageSkia> imageSkia = source->createFrameAtIndex(0);
if (!imageSkia) {
rejectPromise();
« no previous file with comments | « no previous file | Source/platform/graphics/BitmapImage.cpp » ('j') | Source/platform/graphics/DeferredImageDecoder.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698