mirror of
https://github.com/hmaxnl/netex.git
synced 2025-04-19 11:38:13 +02:00
16 lines
568 B
C
16 lines
568 B
C
#ifndef NETEX_H
|
|
#define NETEX_H
|
|
|
|
#include <stdio.h>
|
|
|
|
#define PRINT(msg, args...) fprintf(stdout, msg, ##args)
|
|
#define PRINT_LINE(msg, args...) fprintf(stdout, msg "\n", ##args)
|
|
#define WARN(msg, args...) fprintf(stdout, "[Warning]: " msg "\n", ##args)
|
|
#define ERROR(msg, args...) fprintf(stderr, "[ERROR]: " msg "\n", ##args)
|
|
|
|
void netex_init(void);
|
|
void netex_shutdown(void);
|
|
// Creates a socket and bind to that socket on the given port and hostname. If done with the socket close it with 'close()'
|
|
int setup_socket(int port, const char* hostname);
|
|
|
|
#endif //NETEX_H
|