diff options
author | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1998-02-22 01:23:34 +0000 |
---|---|---|
committer | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1998-02-22 01:23:34 +0000 |
commit | 8b617ad77948342faf0917e268e4d001047fec35 (patch) | |
tree | dd116cd81cb2f451314a8140d49159b494396619 /sys/netinet/ip_ah_new.c | |
parent | d14a3197eff39aeb2d1cf2c146a4a56ae0087f59 (diff) |
Changes made for GCC 2.8 -Wall pleasures
Diffstat (limited to 'sys/netinet/ip_ah_new.c')
-rw-r--r-- | sys/netinet/ip_ah_new.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/sys/netinet/ip_ah_new.c b/sys/netinet/ip_ah_new.c index 4721cb5fc4b..9c48aa271e2 100644 --- a/sys/netinet/ip_ah_new.c +++ b/sys/netinet/ip_ah_new.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_ah_new.c,v 1.15 1998/01/21 18:43:32 provos Exp $ */ +/* $OpenBSD: ip_ah_new.c,v 1.16 1998/02/22 01:23:30 niklas Exp $ */ /* * The author of this code is John Ioannidis, ji@tla.org, @@ -511,6 +511,7 @@ ah_new_input(struct mbuf *m, struct tdb *tdb) /* Notify on expiration */ if (tdb->tdb_flags & TDBF_SOFT_PACKETS) + { if (tdb->tdb_cur_packets >= tdb->tdb_soft_packets) { encap_sendnotify(NOTIFY_SOFT_EXPIRE, tdb); @@ -523,8 +524,10 @@ ah_new_input(struct mbuf *m, struct tdb *tdb) encap_sendnotify(NOTIFY_SOFT_EXPIRE, tdb); tdb->tdb_flags &= ~TDBF_SOFT_BYTES; } - + } + if (tdb->tdb_flags & TDBF_PACKETS) + { if (tdb->tdb_cur_packets >= tdb->tdb_exp_packets) { encap_sendnotify(NOTIFY_HARD_EXPIRE, tdb); @@ -537,6 +540,7 @@ ah_new_input(struct mbuf *m, struct tdb *tdb) encap_sendnotify(NOTIFY_HARD_EXPIRE, tdb); tdb_delete(tdb, 0); } + } return m; } @@ -759,6 +763,7 @@ ah_new_output(struct mbuf *m, struct sockaddr_encap *gw, struct tdb *tdb, /* Notify on expiration */ if (tdb->tdb_flags & TDBF_SOFT_PACKETS) + { if (tdb->tdb_cur_packets >= tdb->tdb_soft_packets) { encap_sendnotify(NOTIFY_SOFT_EXPIRE, tdb); @@ -771,8 +776,10 @@ ah_new_output(struct mbuf *m, struct sockaddr_encap *gw, struct tdb *tdb, encap_sendnotify(NOTIFY_SOFT_EXPIRE, tdb); tdb->tdb_flags &= ~TDBF_SOFT_BYTES; } - + } + if (tdb->tdb_flags & TDBF_PACKETS) + { if (tdb->tdb_cur_packets >= tdb->tdb_exp_packets) { encap_sendnotify(NOTIFY_HARD_EXPIRE, tdb); @@ -785,6 +792,7 @@ ah_new_output(struct mbuf *m, struct sockaddr_encap *gw, struct tdb *tdb, encap_sendnotify(NOTIFY_HARD_EXPIRE, tdb); tdb_delete(tdb, 0); } + } return 0; } |