From 53499e6cd12e64732f2efc509aaa917c3d80bc54 Mon Sep 17 00:00:00 2001 From: Jason Wright Date: Mon, 4 Feb 2002 20:50:43 +0000 Subject: Revision 1.37 was borked... This time, fix the casts and address the void * arithmetic problem correctly in m_zero() --- sys/kern/uipc_mbuf.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sys') diff --git a/sys/kern/uipc_mbuf.c b/sys/kern/uipc_mbuf.c index 680edd62fc5..3683ddcc73f 100644 --- a/sys/kern/uipc_mbuf.c +++ b/sys/kern/uipc_mbuf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uipc_mbuf.c,v 1.49 2002/01/25 15:50:22 art Exp $ */ +/* $OpenBSD: uipc_mbuf.c,v 1.50 2002/02/04 20:50:42 jason Exp $ */ /* $NetBSD: uipc_mbuf.c,v 1.15.4.1 1996/06/13 17:11:44 cgd Exp $ */ /* @@ -902,10 +902,10 @@ m_zero(m) { while (m) { if (m->m_flags & M_PKTHDR) - memset((void *)(m + sizeof(struct m_hdr) + - sizeof(struct pkthdr)), 0, MHLEN); + memset((caddr_t)m + sizeof(struct m_hdr) + + sizeof(struct pkthdr), 0, MHLEN); else - memset((void *)(m + sizeof(struct m_hdr)), 0, MLEN); + memset((caddr_t)m + sizeof(struct m_hdr), 0, MLEN); if ((m->m_flags & M_EXT) && (m->m_ext.ext_free == NULL) && !MCLISREFERENCED(m)) -- cgit v1.2.3