chiark / gitweb /
Python IP addresses: Remove sys.path hacking from test script
[secnet.git] / secnet.h
index bcb8b6a3d56c280b67d21aaef3f28fabe98fe66b..a38b77c00f6f78e3bbe94a3683222f554afe0905 100644 (file)
--- a/secnet.h
+++ b/secnet.h
@@ -3,6 +3,8 @@
 #ifndef secnet_h
 #define secnet_h
 
+#define ADNS_FEATURE_MANYAF
+
 #include "config.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -293,7 +295,7 @@ struct buffer_if;
    will be freed once resolve_answer_fn returns. It is in network byte
    order. */
 typedef void resolve_answer_fn(void *st, const struct comm_addr *addrs,
-                              int naddrs);
+                              int naddrs, const char *failwhy);
 typedef bool_t resolve_request_fn(void *st, cstring_t name,
                                  int remoteport, struct comm_if *comm,
                                  resolve_answer_fn *cb, void *cst);
@@ -342,6 +344,7 @@ struct comm_addr {
        equivalent. */
     struct comm_if *comm;
     union iaddr ia;
+    int ix;
 };
 
 /* Return True if the packet was processed, and shouldn't be passed to
@@ -569,6 +572,7 @@ extern void log_from_fd(int fd, cstring_t prefix, struct log_if *log);
 #define STRING(x) STRING2(x)
 
 #define FILLZERO(obj) (memset(&(obj),0,sizeof((obj))))
+#define ARRAY_SIZE(ary) (sizeof(ary)/sizeof(ary[0]))
 
 /*
  * void COPY_OBJ(  OBJECT& dst, const OBJECT& src);