Another abandoned server code base... this is kind of an ancestor of taskrambler.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

34 lines
617 B

#ifndef __SERVER_H__
#define __SERVER_H__
#include <stdio.h> /* for printf() and fprintf() */
#include <sys/select.h> /* for select system call and related */
#include "socket.h"
#include "logger.h"
#include "cclass.h"
CLASS(SERVER) {
LOGGER logger;
SOCK sock;
unsigned int max_fd;
fd_set fdset;
struct {
SOCK sock;
char * wbuf;
char * rbuf;
unsigned int rpos;
unsigned int wpos;
} conns[FD_SETSIZE];
};
void server_run(SERVER this);
void server_close(SERVER this);
void server_shutdown(SERVER this);
#endif // __SERVER_H__
// vim: set ts=4 sw=4: