-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e45e66b
commit b2aae74
Showing
11 changed files
with
24 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,7 +41,6 @@ | |
__maintainer__ = "Phaseit, Inc." | ||
__maintainer_email = "[email protected]" | ||
|
||
import string | ||
import math | ||
import struct | ||
import sys | ||
|
@@ -57,7 +56,6 @@ | |
else: | ||
from io import BytesIO | ||
|
||
from . import filters | ||
from . import utils | ||
import warnings | ||
import codecs | ||
|
@@ -543,7 +541,6 @@ def _sweepIndirectReferences(self, externMap, data): | |
if debug: print((data, "TYPE", data.__class__.__name__)) | ||
if isinstance(data, DictionaryObject): | ||
for key, value in list(data.items()): | ||
origvalue = value | ||
value = self._sweepIndirectReferences(externMap, value) | ||
if isinstance(value, StreamObject): | ||
# a dictionary value is a stream. streams must be indirect | ||
|
@@ -1752,7 +1749,10 @@ def readObjectHeader(self, stream): | |
idnum = readUntilWhitespace(stream) | ||
extra |= utils.skipOverWhitespace(stream); stream.seek(-1, 1) | ||
generation = readUntilWhitespace(stream) | ||
obj = stream.read(3) | ||
|
||
# although it's not used, it might still be necessary to read | ||
_obj = stream.read(3) # noqa: F841 | ||
|
||
readNonWhitespace(stream) | ||
stream.seek(-1, 1) | ||
if (extra and self.strict): | ||
|
@@ -1938,8 +1938,8 @@ def used_before(num, generation): | |
# The rest of the elements depend on the xref_type | ||
if xref_type == 0: | ||
# linked list of free objects | ||
next_free_object = getEntry(1) | ||
next_generation = getEntry(2) | ||
next_free_object = getEntry(1) # noqa: F841 | ||
next_generation = getEntry(2) # noqa: F841 | ||
elif xref_type == 1: | ||
# objects that are in use but are not compressed | ||
byte_offset = getEntry(1) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import os | ||
import binascii | ||
import sys | ||
|
||
import PyPDF2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters