summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/netatm/port.h12
-rw-r--r--sys/security/lomac/kernel_socket.c4
2 files changed, 10 insertions, 6 deletions
diff --git a/sys/netatm/port.h b/sys/netatm/port.h
index 911f9a2..a9daf4b 100644
--- a/sys/netatm/port.h
+++ b/sys/netatm/port.h
@@ -274,10 +274,12 @@ typedef struct mbuf KBuffer;
(prev)->m_next = (new); \
}
#define KB_UNLINKHEAD(head, next) { \
- MFREE((head), (next)); \
+ (next) = m_free((head)); \
+ (head) = NULL; \
}
#define KB_UNLINK(old, prev, next) { \
- MFREE((old), (next)); \
+ (next) = m_free((old)); \
+ (old) = NULL; \
(prev)->m_next = (next); \
}
#define KB_ISPKT(bfr) (((bfr)->m_flags & M_PKTHDR) != 0)
@@ -407,10 +409,12 @@ typedef struct mbuf KBuffer;
(prev)->m_next = (new); \
}
#define KB_UNLINKHEAD(head, next) { \
- MFREE((head), (next)); \
+ (next) = m_free((head)); \
+ (head) = NULL; \
}
#define KB_UNLINK(old, prev, next) { \
- MFREE((old), (next)); \
+ (next) = m_free((old)); \
+ (old) = NULL; \
(prev)->m_next = (next); \
}
#define KB_ISPKT(bfr) (0)
diff --git a/sys/security/lomac/kernel_socket.c b/sys/security/lomac/kernel_socket.c
index ef0553c..541822b 100644
--- a/sys/security/lomac/kernel_socket.c
+++ b/sys/security/lomac/kernel_socket.c
@@ -644,7 +644,7 @@ dontblock:
m = m->m_next;
} else {
sbfree(&so->so_rcv, m);
- MFREE(m, so->so_rcv.sb_mb);
+ so->so_rcv.sb_mb = m_free(m);
m = so->so_rcv.sb_mb;
}
}
@@ -729,7 +729,7 @@ dontblock:
so->so_rcv.sb_mb = m = m->m_next;
*mp = (struct mbuf *)0;
} else {
- MFREE(m, so->so_rcv.sb_mb);
+ so->so_rcv.sb_mb = m_free(m);
m = so->so_rcv.sb_mb;
}
if (m)
OpenPOWER on IntegriCloud