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

Re: subversion cross compile (arm)

From: Takács András <wakoond_at_gmail.com>
Date: Fri, 3 Dec 2010 16:55:13 +0100

One more interesting addition:

The representation_string function is called from svn_fs_fs__write_noderev.
Here at the nodrerev->data_rep section I preinted out the revision,
offset, size, enpanded_size fields from the noderev->data_rep
structure:

rev 0
offs 4618629949752868864
size 4
exp size 4
md5 2d2977d1c96f487abe4a1e202dd03b4e

The offset seems to be quite high. Is it normal?

The next debug step is in the representation_string function. Before
calling the apr_psprintf function, I printed out again the fields:

rs rev 0
rs offs 4618628953320456192
rs size 4
rs exp size 4
rs md5 2d2977d1c96f487abe4a1e202dd03b4e

Compare the offs and the rs offs lines! The values are modified. How????
I did a small test again, and before my debug lines in the
representation_string function, I did this:

rep->offset = 400;

The result:

rs rev 0
rs offs 4618629039219802512
rs size 4
rs exp size 4
rs md5 2d2977d1c96f487abe4a1e202dd03b4e

The offs field modified again, but this isn't 400!!! How????

I think it is a memory corruption thing, but I don't know where to find it!

Thanks a lot every small idea!

András

--
Takács András
Skype: wakoond
GTalk: wakoond
MSN: wakoond_at_freestart.hu
2010/12/3 Takács András <wakoond_at_gmail.com>:
> The problems seems to be somewhere between the generation
> (representation_string) and the writing of the
> /var/svn/testrepo/db/transactions/0-0.txn/node.0.0 file.
> The bugous string will be in the file.
>
> I'll try to locate the bug at the weekend.
>
> András
>
>
>
> --
> Takács András
> Skype: wakoond
> GTalk: wakoond
> MSN: wakoond_at_freestart.hu
>
>
>
> 2010/12/3 Philip Martin <philip.martin_at_wandisco.com>:
>> Takács András <wakoond_at_gmail.com> writes:
>>
>>> 2010/12/3 Philip Martin <philip.martin_at_wandisco.com>:
>>>> Takács András <wakoond_at_gmail.com> writes:
>>>>
>>>>> / # svn mkdir file:///var/svn/testrepo/xxx -m "aaa"
>>>>> fs_fs: [LINE 2082] calling svn_fs_fs__read_noderev
>>>>> fs_fs: [LINE 2140] calling read_rep_offsets '0 0 4 4
>>>>> 2d2977d1c96f487abe4a1e202dd03b4e'
>>>>> read_rep_offsets: [LINE 1947] '0 0 4 4 2d2977d1c96f487abe4a1e202dd03b4e'
>>>>> read_rep_offsets: [LINE 1956] '0'
>>>>> read_rep_offsets: [LINE 1973] '0'
>>>>> read_rep_offsets: [LINE 1984] '4'
>>>>> read_rep_offsets: [LINE 1995] '4'
>>>>> read_rep_offsets: [LINE 2009] '2d2977d1c96f487abe4a1e202dd03b4e'
>>>>> apr_file_open: '/var/svn/testrepo/db/transactions/0-0.txn/node.0.0'
>>>>> Call svn_fsfs__write_noderev in svn_fs_fs__put_node_revision [LINE 2390]
>>>>> svn_fsfs__write_noderev HEADER_TEXT
>>>>> rev 0
>>>>> offs 4618626049922564096
>>>>> size 4
>>>>> exp size 4
>>>>> md5 2d2977d1c96f487abe4a1e202dd03b4e
>>>>> svn_fsfs__write_noderev HEADER_TEXT OK
>>>>
>>>> So here the file should contain the line
>>>>
>>>> text: 0 0 4 4 2d2977d1c96f487abe4a1e202dd03b4e
>>>
>>> This line is in /var/svn/testrepo/db/revs/0/0 file.
>>> It is parsed correctly.
>>
>> The new file
>>  '/var/svn/testrepo/db/transactions/0-0.txn/node.0.0'
>> should also contain that same line.  Does it?
>>
>>>>> fs_fs: [LINE 2082] calling svn_fs_fs__read_noderev
>>>>> fs_fs: [LINE 2140] calling read_rep_offsets '0 4 4 531704 (null)'
>>>>> read_rep_offsets: [LINE 1947] '0 4 4 531704 (null)'
>>>>
>>>> but here when you read the file you get the wrong data.  Is the file
>>>> corrupt or does the problem occur svn_fs_fs__read_noderev?
>>>
>>> I don't know the internal mechanism of subversion, so I don't know
>>> what is this second text representation.
>>> I guess it is generated for the committing (next) revision.
>>> The issue coming (I think) from this function: svn_fsfs__write_noderev
>>> which is called from svn_fs_fs__put_node_revision
>>
>> The problem appears to be the data in the transactions/0-0.txn/node.0.0
>> file.  Either it is getting corrupted when written to the file, or when
>> subsequently read from the file.
>>
>> --
>> Philip
>>
>
Received on 2010-12-03 16:56:11 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.