From owner-cvs-all Thu Jun 13 18:36:39 2002 Delivered-To: cvs-all@freebsd.org Received: from sdns.kv.ukrtel.net (sdns.kv.ukrtel.net [195.5.27.246]) by hub.freebsd.org (Postfix) with ESMTP id 31BA637B415; Thu, 13 Jun 2002 18:36:30 -0700 (PDT) Received: from vega.vega.com (195.5.51.243 [195.5.51.243]) by sdns.kv.ukrtel.net with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2650.21) id M2L7D6PB; Fri, 14 Jun 2002 04:38:32 +0300 Received: (from max@localhost) by vega.vega.com (8.11.6/8.11.3) id g5E1aRA10213; Fri, 14 Jun 2002 04:36:27 +0300 (EEST) (envelope-from sobomax@FreeBSD.org) From: Maxim Sobolev Message-Id: <200206140136.g5E1aRA10213@vega.vega.com> Subject: Re: cvs commit: src/usr.bin/sed main.c To: jmallett@FreeBSD.org (Juli Mallett) Date: Fri, 14 Jun 2002 04:36:27 +0300 (EEST) Cc: sobomax@FreeBSD.org (Maxim Sobolev), cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org In-Reply-To: <20020613183132.A74832@FreeBSD.ORG> from "Juli Mallett" at Jun 13, 2002 06:31:32 PM X-Mailer: ELM [version 2.5 PL5] MIME-Version: 1.0 Content-Type: text/plain; charset=DISPLAY Content-Transfer-Encoding: 8bit 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 > > * Maxim Sobolev escriurères > > sobomax 2002/06/13 18:28:52 PDT > > > > Modified files: > > usr.bin/sed main.c > > Log: > > Fix one serious bug and one potential problem with in-place editing code: > > > > - original version of code worked incorrectly when more than one > > input files were specified - it was moving the last line from the 1st file > > to be the first line of the 2nd, last line of the 2nd to be the first > > line of the 3rd and so on; > > > > - use mmap()->write() to create temporary file instead of > > malloc()->read()->write(), which was not only slower, but also did not > > bother to free allocated memory once backup file was created, potentially > > leading to memory exhausting when regex is applied to a big file or a large > > number of small ones. > > I'll let you handle MFC'ing -i and the manpage changes now. Ok. -Maxim To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message