Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torch/threads-ffi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRui Guo <guorui.xt@gmail.com>2016-11-04 06:33:30 +0300
committerRui Guo <guorui.xt@gmail.com>2016-11-04 06:33:30 +0300
commitf4f9c76981e309ef5fdc4771f394669ce755dbc2 (patch)
tree14827015428abf290b0c029a811728a14fd954ca
parent7e14ba31d0b1d2e48907d5bf5b2f876e865669ae (diff)
get threads work for old msvc before 2015
-rw-r--r--lib/threads.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/threads.c b/lib/threads.c
index 46a771d..f08f095 100644
--- a/lib/threads.c
+++ b/lib/threads.c
@@ -20,7 +20,8 @@ static int thread_new(lua_State *L)
luaL_error(L, "threads: out of memory");
memcpy(code_dup, code, len+1);
-#ifdef _WIN32
+#ifdef _MSC_VER
+#define snprintf _snprintf
#define LIBTHREADSMAIN "threadsmain.dll"
#else
#define LIBTHREADSMAIN "libthreadsmain.so"