summaryrefslogtreecommitdiff
path: root/sys/net/pfvar.h
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2008-05-08 08:05:17 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2008-05-08 08:05:17 +0000
commita49f81bb6fb16a6e483d1628991511342597c556 (patch)
tree0022793cd0f10cc00da8d1b453d52b734ed051fb /sys/net/pfvar.h
parentc7f04fbb1d6091e63f6b91fb10d182d4d997f955 (diff)
reorder elements in pf_state_peer to avoid wasting memory. cvs blame
shows that 3 developers screwed this up. look carefully at this diff and learn how to avoid wasting memory. on a 64 bit architecture, each of these was using 40 bytes instead of 32. ok henning
Diffstat (limited to 'sys/net/pfvar.h')
-rw-r--r--sys/net/pfvar.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h
index bb9bcaa9a0a..b186c9b2556 100644
--- a/sys/net/pfvar.h
+++ b/sys/net/pfvar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: pfvar.h,v 1.263 2008/05/07 07:07:29 markus Exp $ */
+/* $OpenBSD: pfvar.h,v 1.264 2008/05/08 08:05:16 deraadt Exp $ */
/*
* Copyright (c) 2001 Daniel Hartmeier
@@ -677,16 +677,16 @@ struct pf_state_host {
};
struct pf_state_peer {
+ struct pf_state_scrub *scrub; /* state is scrubbed */
u_int32_t seqlo; /* Max sequence number sent */
u_int32_t seqhi; /* Max the other end ACKd + win */
u_int32_t seqdiff; /* Sequence number modulator */
u_int16_t max_win; /* largest window (pre scaling) */
+ u_int16_t mss; /* Maximum segment size option */
u_int8_t state; /* active state level */
u_int8_t wscale; /* window scaling factor */
- u_int16_t mss; /* Maximum segment size option */
u_int8_t tcp_est; /* Did we reach TCPS_ESTABLISHED */
- struct pf_state_scrub *scrub; /* state is scrubbed */
- u_int8_t pad[3];
+ u_int8_t pad[1];
};
TAILQ_HEAD(pf_state_queue, pf_state);