summaryrefslogtreecommitdiff
path: root/core/src/xmake/libc/free.c
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/xmake/libc/free.c')
-rw-r--r--core/src/xmake/libc/free.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/core/src/xmake/libc/free.c b/core/src/xmake/libc/free.c
index 89dc65ed0..0b686aeb5 100644
--- a/core/src/xmake/libc/free.c
+++ b/core/src/xmake/libc/free.c
@@ -22,8 +22,8 @@
/* //////////////////////////////////////////////////////////////////////////////////////
* trace
*/
-#define TB_TRACE_MODULE_NAME "free"
-#define TB_TRACE_MODULE_DEBUG (0)
+#define TB_TRACE_MODULE_NAME "free"
+#define TB_TRACE_MODULE_DEBUG (0)
/* //////////////////////////////////////////////////////////////////////////////////////
* includes
@@ -33,14 +33,13 @@
/* //////////////////////////////////////////////////////////////////////////////////////
* implementation
*/
-tb_int_t xm_libc_free(lua_State* lua)
-{
- // check
+tb_int_t xm_libc_free(lua_State *lua) {
tb_assert_and_check_return_val(lua, 0);
// do free
tb_pointer_t data = (tb_pointer_t)(tb_size_t)luaL_checkinteger(lua, 1);
- if (data) tb_free(data);
+ if (data) {
+ tb_free(data);
+ }
return 0;
}
-