summaryrefslogtreecommitdiff
path: root/src/routing.h
diff options
context:
space:
mode:
authorJesper Jensen <jesper@slashwin.dk>2021-10-27 20:24:30 +0200
committerJesper Jensen <jesper@slashwin.dk>2021-10-27 20:24:30 +0200
commit42a627aab5e47c3f3e05460322b9c1c3f2c69214 (patch)
tree031e8a09ec26229b31f58e2189d0023898881d20 /src/routing.h
parent38f176ca9c1f21fc11b3ccc6aa45bd2f47e2eab7 (diff)
Increase payload sizemainflush
Diffstat (limited to 'src/routing.h')
-rw-r--r--src/routing.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/routing.h b/src/routing.h
index a7cd8c6..f4164fe 100644
--- a/src/routing.h
+++ b/src/routing.h
@@ -6,6 +6,12 @@
#include <time.h>
#include <stdio.h>
+#define RT_IDBITS 160
+#define RT_BSIZE 8
+// The 3 here is log2(BUCKETSIZE), since the final bucket will contain all those combinations
+#define RT_BBITS 3
+#define RT_SIZE (RT_IDBITS * RT_BSIZE)
+
struct addr {
uint32_t ip;
uint16_t port;