Date: Tue, 02 Mar 2010 19:19:43 -0800 From: Maxim Sobolev <sobomax@FreeBSD.org> To: Xin LI <delphij@gmail.com> Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r204615 - head/sbin/newfs Message-ID: <4B8DD54F.6060302@FreeBSD.org> In-Reply-To: <a78074951003021808y1afb3f28m35a55876245a9e7d@mail.gmail.com> References: <201003030205.o2325AMY010089@svn.freebsd.org> <a78074951003021808y1afb3f28m35a55876245a9e7d@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Xin LI wrote: > On Tue, Mar 2, 2010 at 6:05 PM, Maxim Sobolev <sobomax@freebsd.org> wrote: >> Author: sobomax >> Date: Wed Mar 3 02:05:09 2010 >> New Revision: 204615 >> URL: http://svn.freebsd.org/changeset/base/204615 >> >> Log: >> Teach newfs(8) to understand size modifiers for all options taking >> size or size-like argument. I.e. "-s 32k" instead of "-s 32768". >> Size parsing function has been shamelessly stolen from the truncate(1). >> I'm sure many sysadmins out there will appreciate this small >> improvement. > > Bikeshed: why not expand_number()? I did not know that function existed, but even if I did, I am really not sure if adding dependency on external library just to save 200 bytes of code worth it. Considering that newfs(8) is often embedded into various space-tight/custom things, adding dependency could cause more harm than good. In any case, I do not feel strongly about that, so I can change it to use libutil if people feel like it. -Maxim
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4B8DD54F.6060302>