Make sure we write out bytes, not memory.

This commit is contained in:
Mike Auty
2018-04-14 23:52:59 +01:00
parent f25d059d49
commit 8e5291ecb4
+1 -1
View File
@@ -225,7 +225,7 @@ class CommandLine(interfaces.plugins.FileConsumerInterface):
if not os.path.exists(output_filename):
with open(output_filename, "wb") as current_file:
current_file.write(filedata.data.getbuffer())
current_file.write(filedata.data.getvalue())
vollog.log(logging.INFO, "Saved stored plugin file: {}".format(output_filename))
else:
vollog.warning("Refusing to overwrite an existing file: {}".format(output_filename))