sysdis-tp/server.h

40 lines
771 B
C
Raw Permalink Normal View History

2017-02-01 18:11:53 +00:00
#ifndef _SERVER_H_
#define _SERVER_H_
#include <stdio.h>
#include <stdlib.h>
2017-02-02 10:18:34 +00:00
#include <arpa/inet.h>
2017-02-01 18:11:53 +00:00
#include <string.h>
#include <unistd.h>
#include <sys/types.h>
#include <netdb.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <errno.h>
2017-02-14 08:33:48 +00:00
#include <pthread.h>
2017-02-22 11:35:41 +00:00
#include "RPC/server.h"
2017-02-02 10:18:34 +00:00
#include "lib.h"
2017-02-01 18:11:53 +00:00
2017-02-14 08:33:48 +00:00
// DEFINITIONS
typedef struct{
int socket;
int index;
} pthread_arg_wrapper;
// VARIABLES
static pthread_t managers[maxClients]; // containa THREADS
static int a_managers[maxClients] = {0}; // contains THREADS actifs
/************************************************
**** Signatures ****
************************************************/
void* manageClient(void* pthread_args);
2017-02-01 18:11:53 +00:00
#endif