best makefile
[webserver.git] / server.h
... / ...
CommitLineData
1#ifndef __SERVER_H__
2#define __SERVER_H__
3
4#ifdef _WIN32 /* Windows */
5#include <ws2tcpip.h>
6typedef SOCKET socket_t;
7#else /* Posix */
8typedef int socket_t;
9#endif
10
11void init_network_context (void);
12void terminate_network_context (void);
13
14int open_listening_socket (int port);
15int accept_incoming_connection (void);
16
17void close_connection (void);
18
19int receive_data (char **pdata);
20int send_data (char *data, int len);
21
22#endif /* __SERVER_H__ */
23
24/* vim: set ts=4 sw=4 et: */