diff --git a/src/include/datastorage.h b/src/include/datastorage.h index 911f86e..81df38b 100644 --- a/src/include/datastorage.h +++ b/src/include/datastorage.h @@ -55,11 +55,8 @@ typedef struct client_s { // Array - - #define ARRAY_CLIENT_LEN 1000 -#define TIME_THRESHOLD_CLIENT 60 -#define TIME_THRESHOLD_CLIENT_UPDATE 10 +#define TIME_THRESHOLD_CLIENT 5 struct client_s client_array[ARRAY_CLIENT_LEN]; pthread_mutex_t client_array_mutex; diff --git a/src/main.c b/src/main.c index ebe1572..726e36c 100644 --- a/src/main.c +++ b/src/main.c @@ -58,12 +58,7 @@ int main(int argc, char **argv) { printf("\n mutex init failed\n"); return 1; } - - if (pthread_mutex_init(&send_mutex, NULL) != 0) { - printf("\n mutex init failed\n"); - return 1; - } - + init_socket_runopts(opt_broadcast_ip, opt_broadcast_port, 1); pthread_t tid_probe;