mirror of
https://github.com/logicog/RTLPlayground.git
synced 2026-08-30 14:52:51 +08:00
Add simulation tool running on x86 host for web-pages of an RTL8372 switch
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
#ifndef server_h
|
||||
#define server_h
|
||||
|
||||
#include <netinet/in.h>
|
||||
|
||||
#define BUFFER_SIZE 16000
|
||||
|
||||
struct Server {
|
||||
int domain;
|
||||
int port;
|
||||
int service;
|
||||
int protocol;
|
||||
int backlog;
|
||||
u_long interface;
|
||||
|
||||
int socket;
|
||||
struct sockaddr_in address;
|
||||
|
||||
void (*launch)(struct Server *server);
|
||||
};
|
||||
|
||||
struct Server server_Constructor(int port, void (*launch)(struct Server *server));
|
||||
void launch(struct Server *server);
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user