svn commit: r306849 - head/sys/contrib/ipfilter/netinet
Kevin Lo
kevlo at FreeBSD.org
Sat Oct 8 14:57:22 UTC 2016
Author: kevlo
Date: Sat Oct 8 14:57:21 2016
New Revision: 306849
URL: https://svnweb.freebsd.org/changeset/base/306849
Log:
In case of removal of m_copy() the macro should remain named M_COPY()
in ip_compat.h after r305824. Leaving as vanilla as possible aids in
future maintenance and upgrades.
Suggested by: glebius, cy
Modified:
head/sys/contrib/ipfilter/netinet/fil.c
head/sys/contrib/ipfilter/netinet/ip_compat.h
Modified: head/sys/contrib/ipfilter/netinet/fil.c
==============================================================================
--- head/sys/contrib/ipfilter/netinet/fil.c Sat Oct 8 14:32:43 2016 (r306848)
+++ head/sys/contrib/ipfilter/netinet/fil.c Sat Oct 8 14:57:21 2016 (r306849)
@@ -3226,7 +3226,7 @@ filterdone:
fdp = fin->fin_dif;
if ((fdp != NULL) && (fdp->fd_ptr != NULL) &&
(fdp->fd_ptr != (void *)-1)) {
- mc = M_COPYM(fin->fin_m);
+ mc = M_COPY(fin->fin_m);
if (mc != NULL)
ipf_fastroute(mc, &mc, fin, fdp);
}
Modified: head/sys/contrib/ipfilter/netinet/ip_compat.h
==============================================================================
--- head/sys/contrib/ipfilter/netinet/ip_compat.h Sat Oct 8 14:32:43 2016 (r306848)
+++ head/sys/contrib/ipfilter/netinet/ip_compat.h Sat Oct 8 14:57:21 2016 (r306849)
@@ -212,7 +212,7 @@ struct ether_addr {
# define MSGDSIZE(m) mbufchainlen(m)
# define M_LEN(m) (m)->m_len
# define M_ADJ(m,x) m_adj(m, x)
-# define M_COPYM(x) m_copym((x), 0, M_COPYALL, M_NOWAIT)
+# define M_COPY(x) m_copym((x), 0, M_COPYALL, M_NOWAIT)
# define M_DUP(m) m_dup(m, M_NOWAIT)
# define IPF_PANIC(x,y) if (x) { printf y; panic("ipf_panic"); }
typedef struct mbuf mb_t;
@@ -367,7 +367,7 @@ typedef struct mb_s {
# define MSGDSIZE(m) msgdsize(m)
# define M_LEN(m) (m)->mb_len
# define M_ADJ(m,x) (m)->mb_len += x
-# define M_COPYM(m) dupmbt(m)
+# define M_COPY(m) dupmbt(m)
# define M_DUP(m) dupmbt(m)
# define GETKTIME(x) gettimeofday((struct timeval *)(x), NULL)
# define MTOD(m, t) ((t)(m)->mb_data)
More information about the svn-src-head
mailing list