[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: failure in 1.4.0-rc4 ruby testsuite on AMD64

From: Nik Clayton <nik_at_ngo.org.uk>
Date: 2006-08-17 19:47:34 CEST

Max Bowsher wrote:
> Kouhei Sutou wrote:
>> Does attached patch solve this problem?
>
> Yes, it does! Congratulations, Kouhei, on tracking this one down. :-)
> Please go ahead and commit it, and nominate it in STATUS for 1.4.x too.
>
>> Index: subversion/bindings/swig/svn_delta.i
>> ===================================================================
>> --- subversion/bindings/swig/svn_delta.i (revision 21073)
>> +++ subversion/bindings/swig/svn_delta.i (working copy)
>> @@ -169,7 +169,8 @@
>> char *tbuf;
>> apr_size_t tlen;
>>
>> - tbuf = ALLOCA_N(char, (window->tview_len + 1));
>> + tlen = window->tview_len + 1;
>> + tbuf = ALLOCA_N(char, tlen);
>> svn_txdelta_apply_instructions(window, sbuf, tbuf, &tlen);
>>
>> return rb_str_new(tbuf, tlen);

Should a comment be added, explaining that this is here to fix a bug? In 6
months time someone's liable to look at that code, wonder why there's a
temporary variable, and probably put things back in the name of making the
code cleaner.

A

   # Note: ALLOCA_N(char, (window->tview_len + 1)); triggers a bug

comment would help avert this.

N

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Aug 17 21:29:55 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.