Replace MinGW with Windows to avoid ambiguities
[tinc] / src / net.h
index b179288..1765b1c 100644 (file)
--- a/src/net.h
+++ b/src/net.h
@@ -36,6 +36,8 @@
 #define MTU 1518        /* 1500 bytes payload + 14 bytes ethernet header + 4 bytes VLAN tag */
 #endif
 
+#define MINMTU 512      /* Below this we don't consider UDP to be working */
+
 /* MAXSIZE is the maximum size of an encapsulated packet: MTU + seqno + srcid + dstid + padding + HMAC + compressor overhead */
 #define MAXSIZE (MTU + 4 + sizeof(node_id_t) + sizeof(node_id_t) + CIPHER_MAX_BLOCK_SIZE + DIGEST_MAX_SIZE + MTU/64 + 20)
 
@@ -213,7 +215,7 @@ extern void load_all_nodes(void);
 extern void try_tx(struct node_t *n, bool mtu);
 extern void tarpit(int fd);
 
-#ifndef HAVE_MINGW
+#ifndef HAVE_WINDOWS
 #define closesocket(s) close(s)
 #endif