summaryrefslogtreecommitdiffstats
path: root/sys/contrib/ipfilter/netinet/ip_state.c
diff options
context:
space:
mode:
authorcy <cy@FreeBSD.org>2015-09-11 08:27:32 +0000
committercy <cy@FreeBSD.org>2015-09-11 08:27:32 +0000
commit5d85607054ba1bebbc4784a50a940c31ce1d9825 (patch)
tree56e2604dbd3ff80e8a33a2ea7e5e203e94cdcf51 /sys/contrib/ipfilter/netinet/ip_state.c
parent85e8cd93390eb0f4ee5d7d6ac6b9c1e55f7cee83 (diff)
downloadFreeBSD-src-5d85607054ba1bebbc4784a50a940c31ce1d9825.zip
FreeBSD-src-5d85607054ba1bebbc4784a50a940c31ce1d9825.tar.gz
Fixup typos in comments.
Obtained from: NetBSD r1.4. MFC after: 1 week
Diffstat (limited to 'sys/contrib/ipfilter/netinet/ip_state.c')
-rw-r--r--sys/contrib/ipfilter/netinet/ip_state.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/sys/contrib/ipfilter/netinet/ip_state.c b/sys/contrib/ipfilter/netinet/ip_state.c
index 9c6a244..54b7c60 100644
--- a/sys/contrib/ipfilter/netinet/ip_state.c
+++ b/sys/contrib/ipfilter/netinet/ip_state.c
@@ -1,4 +1,4 @@
-/* $FreeBSD$ */
+/* $NetBSD: ip_state.c,v 1.4 2012/12/20 21:42:28 christos Exp $ */
/*
* Copyright (C) 2012 by Darren Reed.
@@ -1054,7 +1054,7 @@ ipf_state_putent(softc, softs, data)
/* to pointers and adjusts running stats for the hash table as appropriate. */
/* */
/* This function can fail if the filter rule has had a population policy of */
-/* IP addresses used with stateful filteirng assigned to it. */
+/* IP addresses used with stateful filtering assigned to it. */
/* */
/* Locking: it is assumed that some kind of lock on ipf_state is held. */
/* Exits with is_lock initialised and held - *EVEN IF ERROR*. */
@@ -1081,7 +1081,7 @@ ipf_state_insert(softc, is, rev)
}
/*
- * If we could trust is_hv, then the modulous would not be needed,
+ * If we could trust is_hv, then the modulus would not be needed,
* but when running with IPFILTER_SYNC, this stops bad values.
*/
hv = is->is_hv % softs->ipf_state_size;
@@ -1672,6 +1672,10 @@ ipf_state_add(softc, fin, stsave, flags)
SBUMPD(ipf_state_stats, iss_bucket_full);
return 4;
}
+
+ /*
+ * No existing state; create new
+ */
KMALLOC(is, ipstate_t *);
if (is == NULL) {
SBUMPD(ipf_state_stats, iss_nomem);
@@ -1683,7 +1687,7 @@ ipf_state_add(softc, fin, stsave, flags)
is->is_rule = fr;
/*
- * Do not do the modulous here, it is done in ipf_state_insert().
+ * Do not do the modulus here, it is done in ipf_state_insert().
*/
if (fr != NULL) {
ipftq_t *tq;
@@ -1711,7 +1715,7 @@ ipf_state_add(softc, fin, stsave, flags)
/*
* It may seem strange to set is_ref to 2, but if stsave is not NULL
* then a copy of the pointer is being stored somewhere else and in
- * the end, it will expect to be able to do osmething with it.
+ * the end, it will expect to be able to do something with it.
*/
is->is_me = stsave;
if (stsave != NULL) {
OpenPOWER on IntegriCloud