From ef955b04b5cfd1042dc1751bb4c82d79aff89f46 Mon Sep 17 00:00:00 2001 From: Jay Berkenbilt Date: Fri, 20 May 2022 11:07:03 -0400 Subject: [PATCH] Bug fix: don't clobber stream length with replaceDict --- libqpdf/QPDF_Stream.cc | 6 ------ 1 file changed, 6 deletions(-) diff --git a/libqpdf/QPDF_Stream.cc b/libqpdf/QPDF_Stream.cc index 11dbe7e3..c3e5f747 100644 --- a/libqpdf/QPDF_Stream.cc +++ b/libqpdf/QPDF_Stream.cc @@ -746,12 +746,6 @@ QPDF_Stream::replaceDict(QPDFObjectHandle const& new_dict) { this->stream_dict = new_dict; setDictDescription(); - QPDFObjectHandle length_obj = this->stream_dict.getKey("/Length"); - if (length_obj.isInteger()) { - this->length = QIntC::to_size(length_obj.getUIntValue()); - } else { - this->length = 0; - } } void