+#ifndef TINC_NET_H
+#define TINC_NET_H
+
/*
net.h -- header for net.c
Copyright (C) 1998-2005 Ivo Timmermans
- 2000-2014 Guus Sliepen <guus@tinc-vpn.org>
+ 2000-2016 Guus Sliepen <guus@tinc-vpn.org>
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
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#ifndef __TINC_NET_H__
-#define __TINC_NET_H__
-
#include "ipv6.h"
#include "cipher.h"
#include "digest.h"
io_t udp;
sockaddr_t sa;
bool bindto;
+ int priority;
} listen_socket_t;
#include "conf.h"
int timeout;
splay_tree_t *config_tree;
struct config_t *cfg;
- struct addrinfo *ai;
+ struct addrinfo *ai; // addresses from config files
struct addrinfo *aip;
+ struct addrinfo *kai; // addresses known via other online nodes (use free_known_addresses())
timeout_t ev;
} outgoing_t;
extern void device_disable(void);
extern bool setup_myself_reloadable(void);
extern bool setup_network(void);
-extern void setup_outgoing_connection(struct outgoing_t *);
+extern void setup_outgoing_connection(struct outgoing_t *, bool verbose);
extern void try_outgoing_connections(void);
extern void close_network_connections(void);
extern int main_loop(void);
extern void purge(void);
extern void retry(void);
extern int reload_configuration(void);
-extern void load_all_subnets(void);
extern void load_all_nodes(void);
extern void try_tx(struct node_t *n, bool);
#define closesocket(s) close(s)
#endif
-#endif /* __TINC_NET_H__ */
+#endif