From owner-freebsd-fs@FreeBSD.ORG Mon Mar 22 00:10:09 2010 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 877CD1065675; Mon, 22 Mar 2010 00:10:09 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-jnhn.mail.uoguelph.ca (esa-jnhn.mail.uoguelph.ca [131.104.91.44]) by mx1.freebsd.org (Postfix) with ESMTP id 238118FC27; Mon, 22 Mar 2010 00:10:09 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvsEAK5SpkuDaFvH/2dsb2JhbACbOnO5AoR9BA X-IronPort-AV: E=Sophos;i="4.51,284,1267419600"; d="scan'208";a="69443151" Received: from danube.cs.uoguelph.ca ([131.104.91.199]) by esa-jnhn-pri.mail.uoguelph.ca with ESMTP; 21 Mar 2010 20:10:08 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by danube.cs.uoguelph.ca (Postfix) with ESMTP id 730A41084146; Sun, 21 Mar 2010 20:10:08 -0400 (EDT) X-Virus-Scanned: amavisd-new at danube.cs.uoguelph.ca Received: from danube.cs.uoguelph.ca ([127.0.0.1]) by localhost (danube.cs.uoguelph.ca [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id D3YsOcAqO5ts; Sun, 21 Mar 2010 20:10:08 -0400 (EDT) Received: from muncher.cs.uoguelph.ca (muncher.cs.uoguelph.ca [131.104.91.102]) by danube.cs.uoguelph.ca (Postfix) with ESMTP id EAD231084138; Sun, 21 Mar 2010 20:10:07 -0400 (EDT) Received: from localhost (rmacklem@localhost) by muncher.cs.uoguelph.ca (8.11.7p3+Sun/8.11.6) with ESMTP id o2M0N3501101; Sun, 21 Mar 2010 20:23:03 -0400 (EDT) X-Authentication-Warning: muncher.cs.uoguelph.ca: rmacklem owned process doing -bs Date: Sun, 21 Mar 2010 20:23:02 -0400 (EDT) From: Rick Macklem X-X-Sender: rmacklem@muncher.cs.uoguelph.ca To: Mikolaj Golub In-Reply-To: <86tys9eqo6.fsf@kopusha.onet> Message-ID: References: <201003171120.o2HBK3CV082081@freefall.freebsd.org> <20100317113953.GA14582@icarus.home.lan> <86tys9eqo6.fsf@kopusha.onet> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: bug-followup@FreeBSD.org, freebsd-fs@FreeBSD.org, Kai Kockro , danny@cs.huji.ac.il Subject: Re: kern/144330: [nfs] mbuf leakage in nfsd with zfs X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Mar 2010 00:10:09 -0000 On Sun, 21 Mar 2010, Mikolaj Golub wrote: > > Reviewing rpc/svc.c:svc_getreq() it looks for me that for RS_DONE case args > are nevere freed. Shouldn't it be like in the attached patch? > Oops, I meant to ask Daniel Braniss (not Jeremy) w.r.t testing the patch, since he can easily reproduce the problem. Of course, I'd appreciate anyone who can test it to do so and let us know how it goes. Daniel, here's the patch just in case you didn't see Mikolaj's email. rick Mikolaj's patch: --- sys/rpc/svc.c.orig 2010-03-21 10:17:20.000000000 +0200 +++ sys/rpc/svc.c 2010-03-21 10:20:05.000000000 +0200 @@ -819,6 +819,7 @@ svc_getreq(SVCXPRT *xprt, struct svc_req free(r->rq_addr, M_SONAME); r->rq_addr = NULL; } + m_freem(args); goto call_done; default: