mirror of
https://github.com/noDRM/DeDRM_tools.git
synced 2026-03-22 05:48:57 +00:00
Compare commits
2 Commits
e16748e854
...
a30405bebf
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a30405bebf | ||
|
|
901a6c091d |
@@ -83,5 +83,6 @@ List of changes since the fork of Apprentice Harper's repository:
|
|||||||
- Update the README (fixes #136) to indicate that Apprentice Harper's version is no longer being updated.
|
- Update the README (fixes #136) to indicate that Apprentice Harper's version is no longer being updated.
|
||||||
- Fix a bug where PDFs with empty arrays (`<>`) in a PDF object failed to decrypt, fixes #183.
|
- Fix a bug where PDFs with empty arrays (`<>`) in a PDF object failed to decrypt, fixes #183.
|
||||||
- Automatically strip whitespace from entered Amazon Kindle serial numbers, should fix #158.
|
- Automatically strip whitespace from entered Amazon Kindle serial numbers, should fix #158.
|
||||||
- Obok: Add new setting option "Add new entry" for duplicate books to always add them to the Calibre database as a new book. Untested. Should fix #148.
|
- Obok: Add new setting option "Add new entry" for duplicate books to always add them to the Calibre database as a new book. Fixes #148.
|
||||||
- Obok: Fix where changing the Calibre UI language to some languages would cause the "duplicate book" setting to reset. Untested.
|
- Obok: Fix where changing the Calibre UI language to some languages would cause the "duplicate book" setting to reset.
|
||||||
|
- Fix Python3 bug in stylexml2css.php script, fixes #232.
|
||||||
|
|||||||
@@ -1636,12 +1636,14 @@ class PDFDocument(object):
|
|||||||
else:
|
else:
|
||||||
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
||||||
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
||||||
|
if len(bookkey) > 0:
|
||||||
print("bookkey[0] is %d" % bookkey[0])
|
print("bookkey[0] is %d" % bookkey[0])
|
||||||
raise ADEPTError('error decrypting book session key - mismatched length')
|
raise ADEPTError('error decrypting book session key - mismatched length')
|
||||||
else:
|
else:
|
||||||
# proper length unknown try with whatever you have
|
# proper length unknown try with whatever you have
|
||||||
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
||||||
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
||||||
|
if len(bookkey) > 0:
|
||||||
print("bookkey[0] is %d" % ord(bookkey[0]))
|
print("bookkey[0] is %d" % ord(bookkey[0]))
|
||||||
if ebx_V == 3:
|
if ebx_V == 3:
|
||||||
V = 3
|
V = 3
|
||||||
@@ -1708,12 +1710,14 @@ class PDFDocument(object):
|
|||||||
else:
|
else:
|
||||||
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
||||||
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
||||||
|
if len(bookkey) > 0:
|
||||||
print("bookkey[0] is %d" % bookkey[0])
|
print("bookkey[0] is %d" % bookkey[0])
|
||||||
raise ADEPTError('error decrypting book session key - mismatched length')
|
raise ADEPTError('error decrypting book session key - mismatched length')
|
||||||
else:
|
else:
|
||||||
# proper length unknown try with whatever you have
|
# proper length unknown try with whatever you have
|
||||||
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
print("ebx_V is %d and ebx_type is %d" % (ebx_V, ebx_type))
|
||||||
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
print("length is %d and len(bookkey) is %d" % (length, len(bookkey)))
|
||||||
|
if len(bookkey) > 0:
|
||||||
print("bookkey[0] is %d" % bookkey[0])
|
print("bookkey[0] is %d" % bookkey[0])
|
||||||
if ebx_V == 3:
|
if ebx_V == 3:
|
||||||
V = 3
|
V = 3
|
||||||
|
|||||||
@@ -181,7 +181,7 @@ class DocParser(object):
|
|||||||
print("Scale not defined!")
|
print("Scale not defined!")
|
||||||
scale = 1.0
|
scale = 1.0
|
||||||
|
|
||||||
if val == "":
|
if not val:
|
||||||
val = 0
|
val = 0
|
||||||
|
|
||||||
if not ((attr == b'hang') and (int(val) == 0)):
|
if not ((attr == b'hang') and (int(val) == 0)):
|
||||||
|
|||||||
Reference in New Issue
Block a user