Commit 0dea2769978d52e56e270fdc5ca868e0f2223cb0
1 parent
802de87c
Fix fix-qdf for empty streams
Showing
2 changed files
with
9 additions
and
1 deletions
ChangeLog
qpdf/fix-qdf.cc
| ... | ... | @@ -294,7 +294,10 @@ QdfFixer::processLines(std::list<std::string>& lines) |
| 294 | 294 | { |
| 295 | 295 | if (matches(re_ignore_newline)) |
| 296 | 296 | { |
| 297 | - --stream_length; | |
| 297 | + if (stream_length > 0) | |
| 298 | + { | |
| 299 | + --stream_length; | |
| 300 | + } | |
| 298 | 301 | } |
| 299 | 302 | else if (matches(re_n_0_obj)) |
| 300 | 303 | { | ... | ... |