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

Unified Diff: third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h

Issue 2081013002: Re-enable DrMemory test for ICOImageDecoderTests.parseAndDecodeByteByByte. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: proper fix (previous wasn't proper) Created 4 years, 6 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h
diff --git a/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h b/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h
index 0f875ffe6328a0940408ba4756d2c8053ba522f9..c4e91b0d1d511feec5ab062f33c2891c82d9ad31 100644
--- a/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h
+++ b/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h
@@ -41,6 +41,7 @@ class PNGImageDecoder;
// This class decodes the ICO and CUR image formats.
class PLATFORM_EXPORT ICOImageDecoder final : public ImageDecoder {
+ WTF_MAKE_NONCOPYABLE(ICOImageDecoder);
scroggo_chromium 2016/06/24 21:36:24 Weird that this wasn't here before...
public:
ICOImageDecoder(AlphaOption, GammaAndColorProfileOption, size_t maxDecodedBytes);
~ICOImageDecoder() override;
@@ -84,7 +85,7 @@ private:
static bool compareEntries(const IconDirectoryEntry& a, const IconDirectoryEntry& b);
// ImageDecoder:
- virtual void decodeSize() { decode(0, true); }
+ void decodeSize() override { decode(0, true); }
size_t decodeFrameCount() override;
void decode(size_t index) override { decode(index, false); }
@@ -159,6 +160,11 @@ private:
typedef Vector<IconDirectoryEntry> IconDirectoryEntries;
IconDirectoryEntries m_dirEntries;
+ // Count of directory entries is parsed from header before initializing
+ // m_dirEntries. m_dirEntries is populated only when full header
+ // information including directory entries is available.
+ size_t m_dirEntriesCount;
+
// The image decoders for the various frames.
typedef Vector<std::unique_ptr<BMPImageReader>> BMPReaders;
BMPReaders m_bmpReaders;
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698