From: Johannes Sixt Date: Wed, 15 Apr 2009 07:39:36 GMT Subject: Re: [PATCH v2] Fix buffer overflow in config parser Message-ID: <49E58F38.5060103@viscovery.net> In-Reply-To: <49E5888D.2090607@viscovery.net> Johannes Sixt schrieb: > Junio C Hamano schrieb: >> Johannes Schindelin writes: >> >>> Hi, >>> >>> On Tue, 14 Apr 2009, Thomas Jarosch wrote: >>> >>>> t/t1303-wacky-config.sh | 9 ++++++++- >>> I like the name! >>> >>>> +LONG_VALUE=`perl -e 'print "x" x 1023," a"'` >>> But should it not be guarded against NO_PERL? >> The right question to ask is a rhetorical "do we need perl to do this?" > > LONG_VALUE=$(printf "x%0.1021dx a", 7) Oops! Make this LONG_VALUE=$(printf "x%01021dx a" 7) -- Hannes