summaryrefslogtreecommitdiff
path: root/sys/net/pf_norm.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2001-08-02 06:59:26 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2001-08-02 06:59:26 +0000
commit1127ec84bc422555400d7ee26510d3079571b3cf (patch)
tree5a0ff7290f620eab776a1b90c2d782c691579a48 /sys/net/pf_norm.c
parentad7d1f629bc27bc24302478e3487c6b67988f478 (diff)
KNF
Diffstat (limited to 'sys/net/pf_norm.c')
-rw-r--r--sys/net/pf_norm.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/sys/net/pf_norm.c b/sys/net/pf_norm.c
index 1063bb1f7db..53e99c59717 100644
--- a/sys/net/pf_norm.c
+++ b/sys/net/pf_norm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pf_norm.c,v 1.4 2001/08/01 23:07:36 provos Exp $ */
+/* $OpenBSD: pf_norm.c,v 1.5 2001/08/02 06:59:25 deraadt Exp $ */
/*
* Copyright 2001 Niels Provos <provos@citi.umich.edu>
@@ -359,8 +359,10 @@ pf_reassemble(struct mbuf **m0, struct pf_fragment *frag,
off += frep->fr_ip->ip_len;
if (off < frag->fr_max &&
(next == NULL || next->fr_ip->ip_off != off)) {
- DPFPRINTF((__FUNCTION__": missing fragment at %d, next %d, max %d\n",
- off, next == NULL ? -1 : next->fr_ip->ip_off, frag->fr_max));
+ DPFPRINTF((__FUNCTION__
+ ": missing fragment at %d, next %d, max %d\n",
+ off, next == NULL ? -1 : next->fr_ip->ip_off,
+ frag->fr_max));
return (NULL);
}
}
@@ -522,7 +524,7 @@ pf_normalize_ip(struct mbuf **m0, int dir, struct ifnet *ifp, u_short *reason)
/* Enforce a minimum ttl, may cause endless packet loops */
if (r->min_ttl && h->ip_ttl < r->min_ttl)
h->ip_ttl = r->min_ttl;
-
+
return (PF_PASS);
drop:
@@ -562,16 +564,16 @@ pf_normalize_tcp(int dir, struct ifnet *ifp, struct mbuf *m, int ipoff,
if (r->proto && r->proto != h->ip_p)
r = r->skip[0];
else if (r->src.mask && !pf_match_addr(r->src.not,
- r->src.addr, r->src.mask, h->ip_src.s_addr))
+ r->src.addr, r->src.mask, h->ip_src.s_addr))
r = r->skip[1];
else if (r->src.port_op && !pf_match_port(r->src.port_op,
- r->src.port[0], r->src.port[1], th->th_sport))
+ r->src.port[0], r->src.port[1], th->th_sport))
r = r->skip[2];
else if (r->dst.mask && !pf_match_addr(r->dst.not,
- r->dst.addr, r->dst.mask, h->ip_dst.s_addr))
+ r->dst.addr, r->dst.mask, h->ip_dst.s_addr))
r = r->skip[3];
else if (r->dst.port_op && !pf_match_port(r->dst.port_op,
- r->dst.port[0], r->dst.port[1], th->th_dport))
+ r->dst.port[0], r->dst.port[1], th->th_dport))
r = r->skip[4];
else if (r->direction != dir)
r = TAILQ_NEXT(r, entries);