diff options
Diffstat (limited to 'plop.c')
-rw-r--r-- | plop.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -23,7 +23,7 @@ /// \return File descriptor of the socket or -1 in case of an error /// \see getaddrinfo(3) // TODO: Handle UNIX sockets -int make_server(const char * node, const char * service) +int plop_make_server(const char * node, const char * service) { struct addrinfo hints = { .ai_family = AF_UNSPEC, @@ -86,7 +86,7 @@ int make_server(const char * node, const char * service) /// \param L Lua state to load the handler into /// \param path Path the script that returns handle is located at /// \param LUA_OK if successful, appropriate Lua error otherwise -int load_handler(lua_State * L, const char * path) +int plop_load_handler(lua_State * L, const char * path) { lua_getglobal(L, "package"); lua_pushstring(L, "loaded"); @@ -119,7 +119,7 @@ int load_handler(lua_State * L, const char * path) /// \param L Server's Lua state /// \param event Event for client /// \return -1 if an error occured -int handle_client(lua_State * L, struct epoll_event * event) +int plop_handle_client(lua_State * L, struct epoll_event * event) { // TODO: Temporary shenanigans to avoid too much changes. struct request * r = (struct request *) event->data.ptr; @@ -158,7 +158,7 @@ int handle_client(lua_State * L, struct epoll_event * event) /// \param efd File descriptor for epoll's context /// \param server File descriptor for server socket /// \return -1 if an error occured -int handle_server(lua_State * L, const int efd, const int server) +int plop_handle_server(lua_State * L, const int efd, const int server) { struct epoll_event e; e.events = EPOLLIN; // TODO: Add EPOLLOUT? |