Diff

util-src/net.c @ 7969:1c6a07606309

util-src: Specify size of various tables to be allocated
author Kim Alvefur <zash@zash.se>
date Thu, 09 Mar 2017 01:20:59 +0100
parent 7931:b619b85e01aa
child 8426:8b612ec00e4a
line wrap: on
line diff
--- a/util-src/net.c	Thu Mar 09 00:59:32 2017 +0100
+++ b/util-src/net.c	Thu Mar 09 01:20:59 2017 +0100
@@ -134,7 +134,7 @@
 		{ NULL, NULL }
 	};
 
-	lua_newtable(L);
+	lua_createtable(L, 0, 1);
 	luaL_setfuncs(L, exports, 0);
 	return 1;
 }