Date: Wed, 08 Sep 2010 13:48:49 +0200 From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= <des@des.no> To: Alexander Best <arundel@freebsd.org> Cc: freebsd-hackers@freebsd.org Subject: Re: expand_number() for fetch'es -B and -S switches Message-ID: <8662ygihge.fsf@ds4.des.no> In-Reply-To: <20100908105050.GA4892@freebsd.org> (Alexander Best's message of "Wed, 8 Sep 2010 10:50:50 %2B0000") References: <20100831180103.GA92584@freebsd.org> <86fwxt5ng1.fsf@ds4.des.no> <20100901222834.GA66517@freebsd.org> <864oe8mpga.fsf@ds4.des.no> <20100902114655.GA9071@freebsd.org> <8639tsl5q0.fsf@ds4.des.no> <20100902122348.GA38047@freebsd.org> <86pqwwjoef.fsf@ds4.des.no> <20100905203757.GA11586@freebsd.org> <86r5h4shbu.fsf@ds4.des.no> <20100908105050.GA4892@freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Alexander Best <arundel@freebsd.org> writes: > Dag-Erling Sm=C3=B8rgrav <des@des.no> writes: > > Alexander Best <arundel@freebsd.org> writes: > > > so how about forgetting about expand_number() and simply > > > introducing a maximum buffer size of 1 megabyte? > > so how about just leaving the code alone? :) > i thought you wanted to have a maximum buffer size of 1MB in fetch? Yes, I was just commenting on the highly roundabout way we followed only to end up almost at the status quo. > right now -B can be any value and it's quite easy to trigger ENOMEM. "don't do that, then!" My suggestion is that if you're going to change it at all, use expand_number() *and* limit it to 1 MB. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?8662ygihge.fsf>