mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
py3: fix reading bytes and trying to write in text mode
This commit is contained in:
parent
9a169c86c7
commit
fbba92281d
@ -716,7 +716,7 @@ def main(args=sys.argv):
|
|||||||
td = "None"
|
td = "None"
|
||||||
if t and len(t) > 0:
|
if t and len(t) > 0:
|
||||||
td = os.path.basename(args[1])+"_thumbnail."+lrf.thumbail_extension()
|
td = os.path.basename(args[1])+"_thumbnail."+lrf.thumbail_extension()
|
||||||
with open(td, "w") as f:
|
with open(td, "wb") as f:
|
||||||
f.write(t)
|
f.write(t)
|
||||||
|
|
||||||
fields = LRFMetaFile.__dict__.items()
|
fields = LRFMetaFile.__dict__.items()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user