* WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
- * @(#) $Header: /tcpdump/master/tcpdump/extract.h,v 1.20 2004-09-23 21:30:12 dyoung Exp $ (LBL)
+ * @(#) $Header: /tcpdump/master/tcpdump/extract.h,v 1.21 2004-09-24 18:21:25 guy Exp $ (LBL)
*/
/* Network to host order macros */
(u_int32_t)*((const u_int8_t *)(p) + 1) << 8 | \
(u_int32_t)*((const u_int8_t *)(p) + 2)))
+#define EXTRACT_64BITS(p) \
+ ((u_int64_t)(u_int64_t)(EXTRACT_32BITS((p) + 0)) << 32 | \
+ (u_int64_t)(EXTRACT_32BITS((p) + 4)))
+
/* Little endian protocol host order macros */
#define EXTRACT_LE_8BITS(p) (*(p))
#ifndef lint
static const char rcsid[] _U_ =
- "@(#) $Header: /tcpdump/master/tcpdump/print-nfs.c,v 1.102 2004-04-17 08:56:14 guy Exp $ (LBL)";
+ "@(#) $Header: /tcpdump/master/tcpdump/print-nfs.c,v 1.103 2004-09-24 18:21:25 guy Exp $ (LBL)";
#endif
#ifdef HAVE_CONFIG_H
{
u_int64_t res;
- res = ((u_int64_t)EXTRACT_32BITS(&dp[0]) << 32) | (u_int64_t)EXTRACT_32BITS(&dp[1]);
+ res = EXTRACT_64BITS((u_int8_t *)dp);
switch (how) {
case SIGNED:
printf("%" PRId64, res);