working on server
This commit is contained in:
32
src/server-loop.h
Normal file
32
src/server-loop.h
Normal file
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* File: server-loop.h
|
||||
* Author: sam
|
||||
*
|
||||
* Created on 18 August 2014, 17:16
|
||||
*/
|
||||
|
||||
#ifndef SERVER_LOOP_H
|
||||
#define SERVER_LOOP_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include "server-state.h"
|
||||
|
||||
#define EP_CONN(event) (server_connection*)event->data.ptr
|
||||
#define EP_EVENT_IS(event, type) ((event->events & type) == type)
|
||||
#define EP_EVENT_ISNOT(event, type) (!EVENT_IS(event, type))
|
||||
|
||||
void server_loop(server_status *state);
|
||||
void* server_loop_read(void* arg);
|
||||
void* server_loop_write(void* arg);
|
||||
void* server_loop_worker(void* arg);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* SERVER_LOOP_H */
|
||||
|
||||
Reference in New Issue
Block a user