Always write binary files in mode wb

This commit is contained in:
Tom Payne
2014-02-23 13:51:42 +01:00
parent 48b85316bb
commit 8e9d5fb0e9
2 changed files with 5 additions and 5 deletions

View File

@@ -111,7 +111,7 @@ def main(argv):
context['getUniforms'] = [uniforms[u] for u in sorted(uniforms.keys())]
if options.output and options.output != '-':
output = open(options.output, 'w')
output = open(options.output, 'wb')
else:
output = sys.stdout
output.write(pystache.render(open(options.template, 'rb').read(), context))