Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 05 Aug 2002 10:54:05 -0400 (EDT)
From:      John Baldwin <jhb@FreeBSD.org>
To:        Shizuka Kudo <shizukakudo_99@yahoo.com>, bmilekic@FreeBSD.rog
Cc:        freebsd-current@freebsd.org
Subject:   Re: current panic on apache2 after sys/kern/subr_mbuf.c commit
Message-ID:  <XFMail.20020805105405.jhb@FreeBSD.org>
In-Reply-To: <20020805022847.14698.qmail@web11407.mail.yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On 05-Aug-2002 Shizuka Kudo wrote:
> 
> --- Shizuka Kudo <shizukakudo_99@yahoo.com> wrote:
>> Dear all,
>> 
>> I have been experiencing panic with Apache2 since Jul 31. The system boot, but panic when
>> someone
>> access the apache2 service. After trace back, the subr_mbuf.c commit at around Jul 30 21:30 GMT
>> is
>> the candidate for this panic. Does anyone see the same problem as me?
>> 
> 
> I think I find the problem which is the missing of assignment on one of the malloc call. Here's
> the patch that seems to fix the problem.
> 
> --- usr/src/sys/kern/subr_mbuf.c        Thu Aug  1 22:24:41 2002
> +++ /usr/src/sys/kern/subr_mbuf.c       Mon Aug  5 10:20:14 2002
> @@ -1051,7 +1051,7 @@
> 
>  #define        _mext_init_ref(m, ref) do {                                    \
>         if ((ref) == NULL)                                              \
> -               malloc(sizeof(u_int), M_MBUF, M_NOWAIT);                \
> +               (m)->m_ext.ref_cnt = malloc(sizeof(u_int), M_MBUF, M_NOWAIT);  \
>         else                                                            \
>                 (m)->m_ext.ref_cnt = (u_int *)(ref);                    \
>         if ((m)->m_ext.ref_cnt != NULL) {                               \

Bosko, is this patch right and should it be committed?  There is obviously
a bug in calling malloc() and not storing the return value.

-- 

John Baldwin <jhb@FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.20020805105405.jhb>