diff options
Diffstat (limited to 'toxcore/network.h')
-rw-r--r-- | toxcore/network.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/toxcore/network.h b/toxcore/network.h index 15ca68e3..d52a02ae 100644 --- a/toxcore/network.h +++ b/toxcore/network.h | |||
@@ -115,6 +115,22 @@ typedef union { | |||
115 | uint8_t uint8[8]; | 115 | uint8_t uint8[8]; |
116 | } IP_Port; | 116 | } IP_Port; |
117 | 117 | ||
118 | |||
119 | /* will replace IP_Port as soon as the complete infrastructure is in place | ||
120 | * removed the unused union and padding also */ | ||
121 | typedef struct { | ||
122 | IPAny ip; | ||
123 | uint16_t port; | ||
124 | } IPAny_Port; | ||
125 | |||
126 | /* ipport_equal | ||
127 | * compares two IPAny_Port structures | ||
128 | * unset means unequal | ||
129 | * | ||
130 | * returns 0 when not equal or when uninitialized | ||
131 | */ | ||
132 | int ipport_equal(IPAny_Port *a, IPAny_Port *b); | ||
133 | |||
118 | typedef struct { | 134 | typedef struct { |
119 | int16_t family; | 135 | int16_t family; |
120 | uint16_t port; | 136 | uint16_t port; |