You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Stefan Küng <to...@gmail.com> on 2007/07/27 15:54:56 UTC

svn_client_diff_peg4() returns inverse diff

Hi,

Calling svn_client_diff_peg4() returns the same diff even with reversed 
revisions:

svn_client_diff_peg4(.... r7(peg),
                           r7(start),
                           WC(end),....)
and
svn_client_diff_peg4(.... r7(peg),
                           WC(start),
                           r7(end),....)
return the exact same diff (always r7:WC, never WC:r7).

Unfortunately, I can't provide a script to reproduce this, because the 
CL client doesn't know WC or WORKING as a valid revision argument.

This happens with the Subversion trunk r25805.

I noticed this when testing the "compare with working copy" feature in 
the TSVN log dialog, where a patchfile is created from the selected 
revision to the working copy, and that patchfile is then 'applied' to 
the working copy to get the files in the selected revision (that's 
faster than to fetch all the files individually in full).

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.net

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn_client_diff_peg4() returns inverse diff

Posted by Stefan Küng <to...@gmail.com>.
Daniel Rall wrote:
> 
> On Jul 27, 2007, at 8:54 AM, Stefan Küng wrote:
> 
>> Hi,
>>
>> Calling svn_client_diff_peg4() returns the same diff even with 
>> reversed revisions:
>>
>> svn_client_diff_peg4(.... r7(peg),
>>                           r7(start),
>>                           WC(end),....)
>> and
>> svn_client_diff_peg4(.... r7(peg),
>>                           WC(start),
>>                           r7(end),....)
>> return the exact same diff (always r7:WC, never WC:r7).
>>
>> Unfortunately, I can't provide a script to reproduce this, because the 
>> CL client doesn't know WC or WORKING as a valid revision argument.
>>
>> This happens with the Subversion trunk r25805.
> 
> Stefan, can you provide an example with the command-line using specific 
> WORKING revisions?  I tried the following (which exercises 
> svn_client_diff_peg4), but was unable to reproduce -- switching the 
> START and END revisions did reverse the diff output.
> 
> svn di -r25820:25862 subversion/libsvn_client@25862

As I already mentioned, it's not possible to give an example with the 
command line: it doesn't understand WC or WORKING as revision arguments.
The problem only occurs if one of the revisions to diff is 'working 
copy', not a revision number.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.net

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn_client_diff_peg4() returns inverse diff

Posted by Daniel Rall <dl...@finemaltcoding.com>.
On Jul 27, 2007, at 8:54 AM, Stefan Küng wrote:

> Hi,
>
> Calling svn_client_diff_peg4() returns the same diff even with  
> reversed revisions:
>
> svn_client_diff_peg4(.... r7(peg),
>                           r7(start),
>                           WC(end),....)
> and
> svn_client_diff_peg4(.... r7(peg),
>                           WC(start),
>                           r7(end),....)
> return the exact same diff (always r7:WC, never WC:r7).
>
> Unfortunately, I can't provide a script to reproduce this, because  
> the CL client doesn't know WC or WORKING as a valid revision argument.
>
> This happens with the Subversion trunk r25805.

Stefan, can you provide an example with the command-line using  
specific WORKING revisions?  I tried the following (which exercises  
svn_client_diff_peg4), but was unable to reproduce -- switching the  
START and END revisions did reverse the diff output.

svn di -r25820:25862 subversion/libsvn_client@25862

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org