Factored ICMP structs and defs into icmpdefs.h.
[icmp-dn.git] / src / idnlookup.c
index 0fd367f..b120c52 100644 (file)
 #include "config.h"
 #endif
 
-struct icmphdr {
-    u_int8_t type;
-    u_int8_t code;
-    u_int16_t checksum;
-};
-
-struct reqhdr {
-    u_int8_t type;
-    u_int8_t code;
-    u_int16_t checksum;
-    u_int16_t id;
-    u_int16_t seq;
-};
-
-struct rephdr {
-    u_int8_t type;
-    u_int8_t code;
-    u_int16_t checksum;
-    u_int16_t id;
-    u_int16_t seq;
-    int32_t ttl;
-    
-};
-
-#define ICMP_NAMEREQ 37
-#define ICMP_NAMEREP 38
+#include "icmpdefs.h"
 
 unsigned char buf[65536];