summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormiau <miaukatzemiau@priveasy.de>2011-12-02 09:34:30 (GMT)
committermiau <miaukatzemiau@priveasy.de>2011-12-02 09:34:30 (GMT)
commitb8ca97e5b02d74c4146808948259a7489fd9b165 (patch)
treec7571273d10b27e949370f0fea216f5c9c3661bf
parent13df2d6db601114db73ed96f3ebe111da9ef1398 (diff)
update max msg len to IPv6 UDP minimum
-rw-r--r--src/common.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/common.h b/src/common.h
index 5f24e57..5ce3c61 100644
--- a/src/common.h
+++ b/src/common.h
@@ -10,9 +10,14 @@
#include <sys/socket.h>
#include <sys/types.h>
-#define SERVERPORT 4950 // the port users will be connecting to
+/* the port users will be connecting to */
+#define SERVERPORT 4950
#define SERVERPORT_S "4950"
-#define MAXBUFLEN 100
+
+/* RFC 2460 requires IPv6 link MTU >= 1280, IPv6 UDP headers sum up to
+ 48 byte, the rest is for us. One extra byte is for the final \0
+ (not transmitted) */
+#define MAXBUFLEN 1233
#define ENP(Cmd, Msg) \
if ((Cmd) == -1) { \
contact: Jan Huwald // Impressum