Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-4]: src/sys/netinet Pull up revisions 1.20-1.21 (requested by s...



details:   https://anonhg.NetBSD.org/src/rev/18155acb79da
branches:  netbsd-1-4
changeset: 470548:18155acb79da
user:      cgd <cgd%NetBSD.org@localhost>
date:      Fri May 05 03:06:42 2000 +0000

description:
Pull up revisions 1.20-1.21 (requested by sommerfeld):
  Add "__attribute__((__packed__))" to structures used to describe
  on-the-wire data, to prevent egcs from making unwarranted assumptions
  about the alignment of these structures.

diffstat:

 sys/netinet/ip.h |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (29 lines):

diff -r fb5c46f1264a -r 18155acb79da sys/netinet/ip.h
--- a/sys/netinet/ip.h  Sun Apr 30 20:36:18 2000 +0000
+++ b/sys/netinet/ip.h  Fri May 05 03:06:42 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ip.h,v 1.18 1998/02/10 01:26:44 perry Exp $    */
+/*     $NetBSD: ip.h,v 1.18.8.1 2000/05/05 03:06:42 cgd Exp $  */
 
 /*
  * Copyright (c) 1982, 1986, 1993
@@ -68,7 +68,7 @@
        u_int8_t  ip_p;                 /* protocol */
        u_int16_t ip_sum;               /* checksum */
        struct    in_addr ip_src, ip_dst; /* source and dest address */
-};
+} __attribute__((__packed__));
 
 #define        IP_MAXPACKET    65535           /* maximum packet size */
 
@@ -142,8 +142,8 @@
                 struct ipt_ta {
                        struct in_addr ipt_addr;
                        n_time ipt_time;
-                } ipt_ta[1];
-       } ipt_timestamp;
+                } ipt_ta[1] __attribute__((__packed__));
+       } ipt_timestamp __attribute__((__packed__));
 };
 
 /* flag bits for ipt_flg */



Home | Main Index | Thread Index | Old Index