From 9a9f80fefacd8a93cc44b4622ce55c6583545970 Mon Sep 17 00:00:00 2001 From: jacob1 Date: Fri, 23 Oct 2015 00:18:41 -0400 Subject: [PATCH] don't add extra newlines when downloading scripts via tpt.getscript --- src/lua/LegacyLuaAPI.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lua/LegacyLuaAPI.cpp b/src/lua/LegacyLuaAPI.cpp index a97b01b15..deebccf2a 100644 --- a/src/lua/LegacyLuaAPI.cpp +++ b/src/lua/LegacyLuaAPI.cpp @@ -1901,7 +1901,7 @@ int luatpt_getscript(lua_State* l) outputfile = NULL; if (!confirmPrompt || ConfirmPrompt::Blocking("File already exists, overwrite?", filename, "Overwrite")) { - outputfile = fopen(filename, "w"); + outputfile = fopen(filename, "wb"); } else { @@ -1911,7 +1911,7 @@ int luatpt_getscript(lua_State* l) } else { - outputfile = fopen(filename, "w"); + outputfile = fopen(filename, "wb"); } if (!outputfile) {