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

Unified Diff: src/images/SkImageDecoder_libjpeg.cpp

Issue 22859042: Only destroy huffman if build succeeded. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 4 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/images/SkImageDecoder_libjpeg.cpp
diff --git a/src/images/SkImageDecoder_libjpeg.cpp b/src/images/SkImageDecoder_libjpeg.cpp
index 788e3526d2d9880e62fcb9a8a612e6262765425e..2bd48186ac5079431bd5c7832d40c99e6d884ee6 100644
--- a/src/images/SkImageDecoder_libjpeg.cpp
+++ b/src/images/SkImageDecoder_libjpeg.cpp
@@ -143,9 +143,9 @@ public:
SkASSERT(fReadHeaderSucceeded);
SkASSERT(!fHuffmanCreated);
jpeg_create_huffman_index(&fCInfo, &fHuffmanIndex);
- fHuffmanCreated = true;
SkASSERT(1 == fCInfo.scale_num && 1 == fCInfo.scale_denom);
- return jpeg_build_huffman_index(&fCInfo, &fHuffmanIndex);
+ fHuffmanCreated = jpeg_build_huffman_index(&fCInfo, &fHuffmanIndex);
+ return fHuffmanCreated;
}
/**
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698