diff --git a/src/config.h b/src/config.h index 3b07d70..1d93d1c 100644 --- a/src/config.h +++ b/src/config.h @@ -1,58 +1,58 @@ /* * Copyright (C) 2011 Jiaju Zhang * Copyright (C) 2013 Philipp Marek * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * This software is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * General Public License for more details. * * You should have received a copy of the GNU General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef _CONFIG_H #define _CONFIG_H #include #include "booth.h" #include "transport.h" #define MAX_NODES 16 #define TICKET_ALLOC 16 struct ticket_config { int weight[MAX_NODES]; int expiry; - char name[BOOTH_NAME_LEN]; + boothc_ticket name; }; struct booth_config { int node_count; int ticket_count; transport_layer_t proto; uint16_t port; struct booth_node node[MAX_NODES]; struct ticket_config ticket[0]; }; struct booth_config *booth_conf; int read_config(const char *path); int check_config(int type); int find_site_in_config(unsigned char *site, struct booth_node **node); static inline struct booth_transport *transport(void) { return booth_transport + booth_conf->proto; } #endif /* _CONFIG_H */