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

Unified Diff: Source/platform/graphics/ImageSource.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/platform/graphics/ImageSource.cpp
diff --git a/Source/platform/graphics/ImageSource.cpp b/Source/platform/graphics/ImageSource.cpp
index 03ae1da016c7d082958c11d66d3d230bd2ea9b79..1bd77db23b12020dd65738c36ef82213911a2959 100644
--- a/Source/platform/graphics/ImageSource.cpp
+++ b/Source/platform/graphics/ImageSource.cpp
@@ -55,14 +55,14 @@ bool ImageSource::initialized() const
return m_decoder;
}
-void ImageSource::setData(SharedBuffer* data, bool allDataReceived)
+void ImageSource::setData(SharedBuffer& data, bool allDataReceived)
{
// Make the decoder by sniffing the bytes.
// This method will examine the data and instantiate an instance of the appropriate decoder plugin.
// If insufficient bytes are available to determine the image type, no decoder plugin will be
// made.
if (!m_decoder)
- m_decoder = DeferredImageDecoder::create(*data, m_alphaOption, m_gammaAndColorProfileOption);
+ m_decoder = DeferredImageDecoder::create(data, m_alphaOption, m_gammaAndColorProfileOption);
if (m_decoder)
m_decoder->setData(data, allDataReceived);
« Source/platform/graphics/DeferredImageDecoder.cpp ('K') | « Source/platform/graphics/ImageSource.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698