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

Re: Perl/Ruby bindings fail in trunk

From: Hyrum K. Wright <hyrum_wright_at_mail.utexas.edu>
Date: Fri, 14 Nov 2008 13:44:30 -0600

Just to clarify: yes, please commit the patch. I'm also working on redoing some
of the FSFS checksum stuff in response to David Glasser's concerns expressed in
TODO-1.6, so it will probably changes in the future. However, having this fix
in now is a good thing (as it may take me a while to get the checksum fixes in.)

-Hyrum

Mark Phippard wrote:
> Go ahead and commit this. Hyrum gave his +1 in IRC. Jeremy Whitlock
> also looked at it.
>
> Thanks
>
> Mark
>
>
>
> On Thu, Nov 13, 2008 at 8:43 AM, Kouhei Sutou <kou_at_cozmixng.org> wrote:
>> In <f16625f20811121745q6ef836f6w196068a04665ac45_at_mail.gmail.com>
>> "Re: Perl/Ruby bindings fail in trunk" on Wed, 12 Nov 2008 18:45:22 -0700,
>> "Jeremy Whitlock" <jcscoobyrs_at_gmail.com> wrote:
>>
>>>> All tests before that one passed on Linux. The segfault kills the test run,
>>>> so I do not know if there will be more errors.
>>> I can confirm this as well.
>> It seems that r33975 misses NULL checks.
>>
>> {{{
>> Add missing NULL checks.
>>
>> * subversion/libsvn_fs_fs/tree.c
>> (fs_file_checksum, apply_textdelta): Add missing NULL check.
>> }}}
>>
>>
>> Thanks,
>> --
>> kou
>>
>> Index: subversion/libsvn_fs_fs/tree.c
>> ===================================================================
>> --- subversion/libsvn_fs_fs/tree.c (revision 34171)
>> +++ subversion/libsvn_fs_fs/tree.c (working copy)
>> @@ -2256,7 +2256,10 @@
>>
>> SVN_ERR(get_dag(&file, root, path, pool));
>> SVN_ERR(svn_fs_fs__dag_file_checksum(&file_checksum, file, pool));
>> - *checksum = (file_checksum->kind == kind) ? file_checksum : NULL;
>> + if (file_checksum && file_checksum->kind == kind)
>> + *checksum = file_checksum;
>> + else
>> + *checksum = NULL;
>> return SVN_NO_ERROR;
>> }
>>
>> @@ -2426,7 +2429,8 @@
>> /* Until we finalize the node, its data_key points to the old
>> contents, in other words, the base text. */
>> SVN_ERR(svn_fs_fs__dag_file_checksum(&checksum, tb->node, pool));
>> - if (tb->base_checksum->kind == checksum->kind
>> + if (checksum
>> + && tb->base_checksum->kind == checksum->kind
>> && !svn_checksum_match(tb->base_checksum, checksum))
>> return svn_error_createf
>> (SVN_ERR_CHECKSUM_MISMATCH,
>>
>>
>
>
>

Received on 2008-11-14 20:44:48 CET

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.