diff --git a/libqpdf/QPDF_objects.cc b/libqpdf/QPDF_objects.cc index 63eb13a4..9e82df99 100644 --- a/libqpdf/QPDF_objects.cc +++ b/libqpdf/QPDF_objects.cc @@ -493,7 +493,7 @@ Xref_table::subsections(std::string& line) auto offset = std::get<2>(sub); file->seek(offset + 20 * toO(count) - 1, SEEK_SET); file->read(line.data(), 1); - if (!(line[0] == '\n' || line[0] == '\n')) { + if (!(line[0] == '\n' || line[0] == '\r')) { return bad_subsections(line, recovery_offset); } qpdf_offset_t pos = file->tell();