summaryrefslogtreecommitdiff
path: root/core/src
diff options
context:
space:
mode:
authorruki <[email protected]>2017-03-30 17:18:23 +0800
committerruki <[email protected]>2017-03-30 17:18:23 +0800
commit3eb49a191bd2c4d0ab4a921d8f167fe5f4b2c491 (patch)
treebfbaf148cafa1b95b36ae207e931529ce27ed4b7 /core/src
parentd3f8282da5629d93acecc5c96258a38b1bd42eed (diff)
support windows x64
Diffstat (limited to 'core/src')
-rw-r--r--core/src/xmake/machine.c2
-rw-r--r--core/src/xmake/os/find.c6
-rw-r--r--core/src/xmake/process/waitlist.c6
3 files changed, 7 insertions, 7 deletions
diff --git a/core/src/xmake/machine.c b/core/src/xmake/machine.c
index c4d1ddd70..84bb69649 100644
--- a/core/src/xmake/machine.c
+++ b/core/src/xmake/machine.c
@@ -201,7 +201,7 @@ static tb_bool_t xm_machine_main_get_program_directory(xm_machine_impl_t* impl,
#ifdef TB_CONFIG_OS_WINDOWS
// get the program directory
- tb_size_t size = GetModuleFileName(tb_null, path, maxn);
+ tb_size_t size = (tb_size_t)GetModuleFileName(tb_null, path, (DWORD)maxn);
tb_assert_and_check_break(size < maxn);
// end
diff --git a/core/src/xmake/os/find.c b/core/src/xmake/os/find.c
index ea847f195..ac336b52d 100644
--- a/core/src/xmake/os/find.c
+++ b/core/src/xmake/os/find.c
@@ -101,8 +101,8 @@ static tb_bool_t xm_os_find_walk(tb_char_t const* path, tb_file_info_t const* in
path += rootlen + 1;
// exclude pathes
- tb_size_t i = 0;
- tb_size_t count = luaL_getn(lua, 5);
+ tb_int_t i = 0;
+ tb_int_t count = luaL_getn(lua, 5);
for (i = 0; i < count && !excluded; i++)
{
// get exclude
@@ -133,7 +133,7 @@ static tb_bool_t xm_os_find_walk(tb_char_t const* path, tb_file_info_t const* in
}
// save this path
- if (!excluded) lua_rawseti(lua, -3, ++*pcount);
+ if (!excluded) lua_rawseti(lua, -3, (tb_int_t)(++*pcount));
// pop this return value
else lua_pop(lua, 1);
}
diff --git a/core/src/xmake/process/waitlist.c b/core/src/xmake/process/waitlist.c
index e7a3f5162..3e5d20aa0 100644
--- a/core/src/xmake/process/waitlist.c
+++ b/core/src/xmake/process/waitlist.c
@@ -77,7 +77,7 @@ tb_int_t xm_process_waitlist(lua_State* lua)
}
// get the processes
- tb_size_t i = 0;
+ tb_int_t i = 0;
tb_process_ref_t processes[64 + 1];
for (i = 0; i < count; i++)
{
@@ -93,14 +93,14 @@ tb_int_t xm_process_waitlist(lua_State* lua)
if (!processes[i])
{
// error
- lua_pushfstring(lua, "process[%ld] is null for process.waitlist", i);
+ lua_pushfstring(lua, "process[%d] is null for process.waitlist", i);
lua_error(lua);
}
}
else
{
// error
- lua_pushfstring(lua, "invalid process[%ld] type(%s) for process.waitlist", i, luaL_typename(lua, -1));
+ lua_pushfstring(lua, "invalid process[%d] type(%s) for process.waitlist", i, luaL_typename(lua, -1));
lua_error(lua);
}