From owner-freebsd-current@FreeBSD.ORG Sat Apr 17 19:52:35 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BA57916A4CE for ; Sat, 17 Apr 2004 19:52:35 -0700 (PDT) Received: from smtp01.syd.iprimus.net.au (smtp01.syd.iprimus.net.au [210.50.30.52]) by mx1.FreeBSD.org (Postfix) with ESMTP id 16D4E43D5A for ; Sat, 17 Apr 2004 19:52:35 -0700 (PDT) (envelope-from tim@robbins.dropbear.id.au) Received: from robbins.dropbear.id.au (203.134.130.44) by smtp01.syd.iprimus.net.au (7.0.024) id 402BA9270182EEA5; Sun, 18 Apr 2004 12:52:34 +1000 Received: by robbins.dropbear.id.au (Postfix, from userid 1000) id ACB8C41C9; Sun, 18 Apr 2004 13:55:10 +1000 (EST) Date: Sun, 18 Apr 2004 13:55:10 +1000 From: Tim Robbins To: Alex Vasylenko Message-ID: <20040418035510.GB5615@cat.robbins.dropbear.id.au> References: <040416140449E.61901@www.mmlab.cse.yzu.edu.tw> <408098A7.6090407@omut.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <408098A7.6090407@omut.org> User-Agent: Mutt/1.4.1i cc: Tai-hwa Liang cc: current@freebsd.org Subject: Re: /usr/bin/less weird memory consumption? X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Apr 2004 02:52:35 -0000 On Fri, Apr 16, 2004 at 10:38:31PM -0400, Alex Vasylenko wrote: > Tai-hwa Liang wrote: > > Anyone tried to view a file contains *hugh* line with /usr/bin/less in > >-CURRENT? > > > >Sample file: > > > > dd if=/dev/zero bs=512 count=1500 | tr '\00' ' ' > test.txt > > > > On my -CURRENT box cvsup'd this morning, "/usr/bin/less text.txt" > > consumes > >about 511 MBytes of memory(see 'top'). -STABLE(less 358) and less 381 on > >Debian doesn't seem to have such problem, though. > > There's a memory leak. The latest less (382) doesn't have this problem. > Use attached patch. Thanks for pointing this out. I've imported less 381, which fixes the memory leak. Tim