- uint8_t ip_vhl; /* header length, version */
-#define IP_V(ip) (((ip)->ip_vhl & 0xf0) >> 4)
-#define IP_HL(ip) ((ip)->ip_vhl & 0x0f)
- uint8_t ip_tos; /* type of service */
- uint16_t ip_len; /* total length */
- uint16_t ip_id; /* identification */
- uint16_t ip_off; /* fragment offset field */
-#define IP_DF 0x4000 /* dont fragment flag */
+ nd_uint8_t ip_vhl; /* header length, version */
+#define IP_V(ip) ((GET_U_1((ip)->ip_vhl) & 0xf0) >> 4)
+#define IP_HL(ip) (GET_U_1((ip)->ip_vhl) & 0x0f)
+ nd_uint8_t ip_tos; /* type of service */
+ nd_uint16_t ip_len; /* total length */
+ nd_uint16_t ip_id; /* identification */
+ nd_uint16_t ip_off; /* fragment offset field */
+#define IP_DF 0x4000 /* don't fragment flag */