write to sys.stdout.buffer and fall back to sys.stdout
This commit is contained in:
parent
e810f3baf4
commit
4d005c8443
1 changed files with 1 additions and 1 deletions
|
@ -347,7 +347,7 @@ parser.add_argument(
|
|||
nargs='+', help='input file(s)')
|
||||
parser.add_argument(
|
||||
'-o', '--output', metavar='out', type=argparse.FileType('wb'),
|
||||
default=sys.stdout, help='output file (default: stdout)')
|
||||
default=getattr(sys.stdout, "buffer", sys.stdout), help='output file (default: stdout)')
|
||||
parser.add_argument(
|
||||
'-d', '--dpi', metavar='dpi', type=positive_float,
|
||||
help='dpi for pdf output (default: 96.0)')
|
||||
|
|
Loading…
Reference in a new issue