diff options
author | Ilya Zhuravlev <zhuravlevilya@ya.ru> | 2013-11-30 21:00:18 +0400 |
---|---|---|
committer | Ilya Zhuravlev <zhuravlevilya@ya.ru> | 2013-11-30 21:00:18 +0400 |
commit | 752e11e11411d72868a406d35538adc5d1126655 (patch) | |
tree | 3b1965bc14a89cd8655d5a308f3ab505cba00eea /src | |
parent | 9a927476ca22a28d0640ef35d95964c3077532ab (diff) | |
download | minetest-752e11e11411d72868a406d35538adc5d1126655.tar.gz minetest-752e11e11411d72868a406d35538adc5d1126655.tar.bz2 minetest-752e11e11411d72868a406d35538adc5d1126655.zip |
Fix MSVC build.
Diffstat (limited to 'src')
-rw-r--r-- | src/jthread/win32/jthread.cpp | 2 | ||||
-rw-r--r-- | src/script/lua_api/l_async_events.h | 10 |
2 files changed, 11 insertions, 1 deletions
diff --git a/src/jthread/win32/jthread.cpp b/src/jthread/win32/jthread.cpp index e56c16271..fc1464064 100644 --- a/src/jthread/win32/jthread.cpp +++ b/src/jthread/win32/jthread.cpp @@ -77,7 +77,7 @@ int JThread::Start() runningmutex.Unlock(); return ERR_JTHREAD_ALREADYRUNNING; } - requeststop = false;e + requeststop = false; runningmutex.Unlock(); continuemutex.Lock(); diff --git a/src/script/lua_api/l_async_events.h b/src/script/lua_api/l_async_events.h index 079a08009..3364bac6e 100644 --- a/src/script/lua_api/l_async_events.h +++ b/src/script/lua_api/l_async_events.h @@ -22,7 +22,17 @@ with this program; if not, write to the Free Software Foundation, Inc., #include <vector> #include <map> + +#ifndef _MSC_VER #include <unistd.h> +#else +#define _WINSOCKAPI_ +#include <windows.h> +static unsigned sleep(unsigned seconds) { + Sleep(seconds * 1000); + return 0; +} +#endif /******************************************************************************/ /* Includes */ |