From 558b49380d8e525243a9b65320aae821aaf33edb Mon Sep 17 00:00:00 2001 From: roland Date: Tue, 19 Mar 1996 19:52:07 +0000 Subject: [PATCH] Wed Feb 14 00:21:17 1996 David Mosberger-Tang * sunrpc/rpc/xdr.h (IXDR_GET_LONG, IXDR_PUT_LONG): change casts to u_int32_t (instead of u_long). --- sunrpc/rpc/xdr.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sunrpc/rpc/xdr.h b/sunrpc/rpc/xdr.h index 6cd3e6fe03..0d9b5df7a2 100644 --- a/sunrpc/rpc/xdr.h +++ b/sunrpc/rpc/xdr.h @@ -203,8 +203,8 @@ struct xdr_discrim { * N.B. and frozen for all time: each data type here uses 4 bytes * of external representation. */ -#define IXDR_GET_LONG(buf) ((long)ntohl((u_long)*(buf)++)) -#define IXDR_PUT_LONG(buf, v) (*(buf)++ = (long)htonl((u_long)v)) +#define IXDR_GET_LONG(buf) ((long)ntohl((u_long)*((u_int32_t*)buf)++)) +#define IXDR_PUT_LONG(buf, v) (*((u_int32_t*)(buf))++ = (long)htonl((u_long)v)) #define IXDR_GET_BOOL(buf) ((bool_t)IXDR_GET_LONG(buf)) #define IXDR_GET_ENUM(buf, t) ((t)IXDR_GET_LONG(buf)) -- 2.11.0