Date: Tue, 20 Mar 2001 02:36:58 -0600 From: "Michael C . Wu" <keichii@iteration.net> To: thinker <thinker@branda.to> Cc: freebsd-current@freebsd.org, imp@freebsd.org Subject: Re: /bin/ls mb patch again Message-ID: <20010320023657.B47174@peorth.iteration.net> In-Reply-To: <20010320163153.A14341@hell.branda.to>; from thinker@branda.to on Tue, Mar 20, 2001 at 04:31:53PM %2B0000 References: <20010320163153.A14341@hell.branda.to>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Mar 20, 2001 at 04:31:53PM +0000, thinker scribbled: | Sorry, I forget to diff with -u. I send the patch again. | Following is mb patch file for /bin/ls. | | ---------- begin --------- | --- util.c.orig Sun Mar 18 16:35:12 2001 | +++ util.c Tue Mar 20 16:11:37 2001 | + if (isprint(c)) { | + while(sz--) | + *ri++ = *p++; | + } else { | + p += sz; | + while(sz--) | + *ri++ = '?'; Warner: Thinker thinks that memset() is too costly to use here to modify one or two bytes. I agreed with him in that filenames can't be that long to justify the memset() overhead. However, with today's CPU power, I think memset()'s overhead will only be noticeable with a large directory filled with data. Please tell Thinker what you think. (DES: please resist the ironies and the -chat post ;) ) -- +-----------------------------------------------------------+ | keichii@iteration.net | keichii@freebsd.org | | http://iteration.net/~keichii | Yes, BSD is a conspiracy. | +-----------------------------------------------------------+ 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?20010320023657.B47174>