* RFC1826/2402 authentication header.
*/
-#ifndef _NETINET6_AH_H_
-#define _NETINET6_AH_H_
+#ifndef ND_AH_H_
+#define ND_AH_H_
struct ah {
nd_uint8_t ah_nxt; /* Next Header */
/* variable size, 32bit bound*/ /* Authentication data */
};
-#endif /*_NETINET6_AH_H_*/
+#endif /* ND_AH_H_ */
* OF SUCH DAMAGE.
*/
-#ifndef _CPACK_H
-#define _CPACK_H
+#ifndef ND_CPACK_H
+#define ND_CPACK_H
#include "netdissect.h"
extern int cpack_advance(struct cpack_state *, const size_t);
-#endif /* _CPACK_H */
+#endif /* ND_CPACK_H */
* SUCH DAMAGE.
*/
-#ifndef _GETSERVENT_H
-#define _GETSERVENT_H
+#ifndef ND_GETSERVENT_H
+#define ND_GETSERVENT_H
#ifdef _NETDB_H_
/* Just in case... */
struct servent *getservent(void);
void setservent (int f);
-#endif /* !_GETSERVENT_H */
+#endif /* ! ND_GETSERVENT_H */
* @(#)ip.h 8.1 (Berkeley) 6/10/93
*/
-#ifndef _NETINET_IP6_H_
-#define _NETINET_IP6_H_
+#ifndef ND_IP6_H_
+#define ND_IP6_H_
/*
* Definition for internet protocol version 6.
#define IP6F_RESERVED_MASK 0x0006 /* reserved bits in ip6f_offlg */
#define IP6F_MORE_FRAG 0x0001 /* more-fragments flag */
-#endif /* not _NETINET_IP6_H_ */
+#endif /* not ND_IP6_H_ */
* POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef _GETOPT_LONG_H_
-#define _GETOPT_LONG_H_
+#ifndef ND_GETOPT_LONG_H_
+#define ND_GETOPT_LONG_H_
/*
* GNU-like getopt_long()/getopt_long_only() with 4.4BSD optreset extension.
extern char *optarg; /* getopt(3) external variables */
extern int optind, opterr, optopt;
-#endif /* !_GETOPT_LONG_H_ */
+#endif /* ! ND_GETOPT_LONG_H_ */
/* Operations on timevals. */
-#ifndef _MICRO_PER_SEC
-#define _MICRO_PER_SEC 1000000
-#endif
-
-#ifndef _NANO_PER_SEC
-#define _NANO_PER_SEC 1000000000
-#endif
+#define ND_MICRO_PER_SEC 1000000
+#define ND_NANO_PER_SEC 1000000000
#define netdissect_timevalclear(tvp) ((tvp)->tv_sec = (tvp)->tv_usec = 0)
(vvp)->tv_sec = (tvp)->tv_sec + (uvp)->tv_sec; \
(vvp)->tv_usec = (tvp)->tv_usec + (uvp)->tv_usec; \
if (nano_prec) { \
- if ((vvp)->tv_usec >= _NANO_PER_SEC) { \
+ if ((vvp)->tv_usec >= ND_NANO_PER_SEC) { \
(vvp)->tv_sec++; \
- (vvp)->tv_usec -= _NANO_PER_SEC; \
+ (vvp)->tv_usec -= ND_NANO_PER_SEC; \
} \
} else { \
- if ((vvp)->tv_usec >= _MICRO_PER_SEC) { \
+ if ((vvp)->tv_usec >= ND_MICRO_PER_SEC) { \
(vvp)->tv_sec++; \
- (vvp)->tv_usec -= _MICRO_PER_SEC; \
+ (vvp)->tv_usec -= ND_MICRO_PER_SEC; \
} \
} \
} while (0)
(vvp)->tv_usec = (tvp)->tv_usec - (uvp)->tv_usec; \
if ((vvp)->tv_usec < 0) { \
(vvp)->tv_sec--; \
- (vvp)->tv_usec += (nano_prec ? _NANO_PER_SEC : \
- _MICRO_PER_SEC); \
+ (vvp)->tv_usec += (nano_prec ? ND_NANO_PER_SEC : \
+ ND_MICRO_PER_SEC); \
} \
} while (0)