X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/10afb02ac804db7fa41a776fd61eff922c09c4df..b717e4dba5930b3a2678c912a891d82cbc92dd9d:/print-radius.c diff --git a/print-radius.c b/print-radius.c index 88c80afe..ca3526bb 100644 --- a/print-radius.c +++ b/print-radius.c @@ -44,7 +44,7 @@ #ifndef lint static const char rcsid[] = - "$Id: print-radius.c,v 1.17 2002-11-09 17:19:29 itojun Exp $"; + "$Id: print-radius.c,v 1.19 2002-12-11 07:14:07 guy Exp $"; #endif #ifdef HAVE_CONFIG_H @@ -134,13 +134,13 @@ struct radius_hdr { u_int8_t code; /* Radius packet code */ u_int8_t id; /* Radius packet id */ u_int16_t len; /* Radius total length */ u_int8_t auth[16]; /* Authenticator */ - } __attribute__((packed)); + }; #define MIN_RADIUS_LEN 20 struct radius_attr { u_int8_t type; /* Attribute type */ u_int8_t len; /* Attribute length */ - } __attribute__((packed)); + }; /* Service-Type Attribute standard values */ @@ -646,7 +646,7 @@ print_attr_address(register u_char *data, u_int length, u_short attr_code ) /*************************************/ /* Returns nothing. */ /*************************************/ -static void print_attr_time(register u_char *data, u_int length, u_short attr_code) +static void print_attr_time(register u_char *data, u_int length, u_short attr_code _U_) { time_t attr_time; char string[26]; @@ -823,7 +823,7 @@ radius_print(const u_char *dat, u_int length) } rad = (struct radius_hdr *)dat; - len = ntohs(rad->len); + len = EXTRACT_16BITS(&rad->len); if (len < MIN_RADIUS_LEN) {