From owner-cvs-all Fri Sep 20 12:40:35 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0DAA737B618; Fri, 20 Sep 2002 12:40:33 -0700 (PDT) Received: from rwcrmhc53.attbi.com (rwcrmhc53.attbi.com [204.127.198.39]) by mx1.FreeBSD.org (Postfix) with ESMTP id B04F743E42; Fri, 20 Sep 2002 12:40:32 -0700 (PDT) (envelope-from julian@elischer.org) Received: from InterJet.elischer.org ([12.232.206.8]) by rwcrmhc53.attbi.com (InterMail vM.4.01.03.27 201-229-121-127-20010626) with ESMTP id <20020920194032.OOJQ8126.rwcrmhc53.attbi.com@InterJet.elischer.org>; Fri, 20 Sep 2002 19:40:32 +0000 Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id MAA20286; Fri, 20 Sep 2002 12:36:50 -0700 (PDT) Date: Fri, 20 Sep 2002 12:36:50 -0700 (PDT) From: Julian Elischer To: John Baldwin Cc: Darren Reed , cvs-all@FreeBSD.org, cvs-committers@FreeBSD.org Subject: Re: cvs commit: src/sys/kern uipc_mbuf.c In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 20 Sep 2002, John Baldwin wrote: > > On 20-Sep-2002 Darren Reed wrote: > > btw, I think m_length() as a function which does something besides return > > the length of an mbuf is wrong. I think that kind of task is better delt > > with by keeping a pointer to the last mbuf in the chain. I'd recommend > > that m_length() do what it suggests it do and have another one, m_lastbuf() > > or something to do that job. Well, no, needing m_lastbuf() just sucks > > bigtime. Some thought to making m_length() a M_LENGTH() might be an idea > > too (that thought crossed my mind elsewhere), but that'd only fit well if > > mbufs were fixed up with a tail pointer. > > FWIW, I agree with this. If the function name needs to be changed to > make it more intuitive, so be it. There is nothing intuitive about > a function named foo_length() not returning the length of 'foo'. > m_iterate() > -- > > John Baldwin <>< 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 cvs-all" in the body of the message