From 39869aaa25ca577faa0da2b6cb83db6db7234342 Mon Sep 17 00:00:00 2001
From: SmallJoker <mk939@ymail.com>
Date: Fri, 22 May 2015 18:26:18 +0200
Subject: Fix Windows build, clean up included headers

Also fix a startup error caused by s_security.cpp
---
 src/script/cpp_api/s_security.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'src/script/cpp_api')

diff --git a/src/script/cpp_api/s_security.cpp b/src/script/cpp_api/s_security.cpp
index abe5b3e97..c46483e95 100644
--- a/src/script/cpp_api/s_security.cpp
+++ b/src/script/cpp_api/s_security.cpp
@@ -264,7 +264,7 @@ bool ScriptApiSecurity::safeLoadFile(lua_State *L, const char *path)
 		fp = stdin;
 		chunk_name = const_cast<char *>("=stdin");
 	} else {
-		fp = fopen(path, "r");
+		fp = fopen(path, "rb");
 		if (!fp) {
 			lua_pushfstring(L, "%s: %s", path, strerror(errno));
 			return false;
-- 
cgit v1.2.3