Skip to content

Commit

Permalink
get_bufreader() skip a tell() call
Browse files Browse the repository at this point in the history
`seek()` returns the position already
  • Loading branch information
mara004 committed Mar 12, 2023
1 parent 74849ad commit e77c8c2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/pypdfium2/_helpers/_internal/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ def __call__(self, _, data, size):

def get_bufreader(buffer):

buffer.seek(0, 2)
file_len = buffer.tell()
file_len = buffer.seek(0, 2)
buffer.seek(0)

reader = pdfium_c.FPDF_FILEACCESS()
Expand Down

0 comments on commit e77c8c2

Please sign in to comment.