aboutgitcodebugslistschat
path: root/inany.c
diff options
context:
space:
mode:
Diffstat (limited to 'inany.c')
-rw-r--r--inany.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/inany.c b/inany.c
index edf0b05..c11e2aa 100644
--- a/inany.c
+++ b/inany.c
@@ -16,6 +16,22 @@
#include "siphash.h"
#include "inany.h"
+const union inany_addr inany_loopback4 = {
+ .v4mapped = {
+ .zero = { 0 },
+ .one = { 0xff, 0xff, },
+ .a4 = IN4ADDR_LOOPBACK_INIT,
+ },
+};
+
+const union inany_addr inany_any4 = {
+ .v4mapped = {
+ .zero = { 0 },
+ .one = { 0xff, 0xff, },
+ .a4 = IN4ADDR_ANY_INIT,
+ },
+};
+
/** inany_ntop - Convert an IPv[46] address to text format
* @src: IPv[46] address
* @dst: output buffer, minimum INANY_ADDRSTRLEN bytes