[poppler] poppler/DCTStream.cc
Albert Astals Cid
aacid at kemper.freedesktop.org
Thu Nov 12 15:57:27 PST 2009
poppler/DCTStream.cc | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
New commits:
commit e55bfeb1ddc60053c5ee5fef840c409891781ce6
Author: Albert Astals Cid <aacid at kde.org>
Date: Fri Nov 13 00:55:37 2009 +0100
jpeg_start_decompress can fail, check it
Fixes KDE bug #214317
diff --git a/poppler/DCTStream.cc b/poppler/DCTStream.cc
index f5ad436..7c6ba70 100644
--- a/poppler/DCTStream.cc
+++ b/poppler/DCTStream.cc
@@ -142,7 +142,11 @@ void DCTStream::reset() {
jpeg_read_header(&cinfo, TRUE);
if (src.abort) return;
- jpeg_start_decompress(&cinfo);
+ if (!jpeg_start_decompress(&cinfo))
+ {
+ src.abort = true;
+ return;
+ }
row_stride = cinfo.output_width * cinfo.output_components;
row_buffer = cinfo.mem->alloc_sarray((j_common_ptr) &cinfo, JPOOL_IMAGE, row_stride, 1);
More information about the poppler
mailing list