diff options
author | Paweł Jastrzębski <pawelj@iosphe.re> | 2019-03-07 11:36:56 +0100 |
---|---|---|
committer | Paweł Jastrzębski <pawelj@iosphe.re> | 2019-03-07 11:36:56 +0100 |
commit | 259800e48b8622233d0a415d7a025f087de7e3cd (patch) | |
tree | 034e08eac3211b45647c6fd3f0248478b52ded4c /kindlecomicconverter/comic2ebook.py | |
parent | Merge pull request #306 from ciromattia/dev (diff) | |
download | kcc-259800e48b8622233d0a415d7a025f087de7e3cd.tar.gz kcc-259800e48b8622233d0a415d7a025f087de7e3cd.tar.bz2 kcc-259800e48b8622233d0a415d7a025f087de7e3cd.zip |
Tweaks for Windows binary
Diffstat (limited to 'kindlecomicconverter/comic2ebook.py')
-rwxr-xr-x | kindlecomicconverter/comic2ebook.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/kindlecomicconverter/comic2ebook.py b/kindlecomicconverter/comic2ebook.py index 7800414..3fe2333 100755 --- a/kindlecomicconverter/comic2ebook.py +++ b/kindlecomicconverter/comic2ebook.py @@ -1033,13 +1033,13 @@ def checkTools(source): source = source.upper() if source.endswith('.CB7') or source.endswith('.7Z') or source.endswith('.RAR') or source.endswith('.CBR') or \ source.endswith('.ZIP') or source.endswith('.CBZ'): - process = Popen('7z', stdout=PIPE, stderr=STDOUT, shell=True) + process = Popen('7z', stdout=PIPE, stderr=STDOUT, stdin=PIPE, shell=True) process.communicate() if process.returncode != 0 and process.returncode != 7: print('ERROR: 7z is missing!') exit(1) if options.format == 'MOBI': - kindleGenExitCode = Popen('kindlegen -locale en', stdout=PIPE, stderr=STDOUT, shell=True) + kindleGenExitCode = Popen('kindlegen -locale en', stdout=PIPE, stderr=STDOUT, stdin=PIPE, shell=True) kindleGenExitCode.communicate() if kindleGenExitCode.returncode != 0: print('ERROR: KindleGen is missing!') @@ -1188,7 +1188,7 @@ def makeMOBIWorker(item): try: if os.path.getsize(item) < 629145600: output = Popen('kindlegen -dont_append_source -locale en "' + item + '"', - stdout=PIPE, stderr=STDOUT, shell=True) + stdout=PIPE, stderr=STDOUT, stdin=PIPE, shell=True) for line in output.stdout: line = line.decode('utf-8') # ERROR: Generic error |