Skip to content

Commit

Permalink
BUG: fix py-pdf#1825 no object follows the comment
Browse files Browse the repository at this point in the history
  • Loading branch information
exiledkingcc committed May 3, 2023
1 parent a04b65b commit f815a68
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pypdf/generic/_data_structures.py
Original file line number Diff line number Diff line change
Expand Up @@ -1016,7 +1016,7 @@ def __parse_content_stream(self, stream: StreamType) -> None:
# encountering a comment -- but read_object assumes that
# following the comment must be the object we're trying to
# read. In this case, it could be an operator instead.
while peek not in (b"\r", b"\n"):
while peek not in (b"\r", b"\n", b""):
peek = stream.read(1)
else:
operands.append(read_object(stream, None, self.forced_encoding))
Expand Down

0 comments on commit f815a68

Please sign in to comment.