aboutsummaryrefslogtreecommitdiff
path: root/src/net.c
diff options
context:
space:
mode:
authorame <[email protected]>2024-01-21 19:35:25 -0600
committerame <[email protected]>2024-01-21 19:35:25 -0600
commit85c4718212e44b0e01485260b5f1574d5c7411a9 (patch)
treeadeb629adaa7078c598385f96c013282b10c9c74 /src/net.c
parentf27507a6cc914b04746f4608a217f5da21aa86a7 (diff)
stuff
Diffstat (limited to 'src/net.c')
-rw-r--r--src/net.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/net.c b/src/net.c
index b0fd09e..7beec3a 100644
--- a/src/net.c
+++ b/src/net.c
@@ -6,6 +6,7 @@
#else
#include <sys/socket.h>
#include <arpa/inet.h>
+#define closesocket close
#endif
#include <sys/types.h>
@@ -208,11 +209,12 @@ int l_send(lua_State* L){
lua_pushstring(L, "client_fd");
lua_gettable(L, res_idx);
int client_fd = luaL_checkinteger(L, -1);
-
+
+ /*
lua_pushvalue(L, res_idx);
lua_pushstring(L, "Content");
- lua_gettable(L, res_idx);
- char* content = (char*)luaL_checkstring(L, -1);
+ lua_gettable(L, res_idx);*/
+ char* content = (char*)luaL_checkstring(L, 2);
lua_pushvalue(L, res_idx);
lua_pushstring(L, "Content-Type");