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

Re: diff and "reverse diff" show different results

From: Stefan Sperling <stsp_at_elego.de>
Date: Fri, 13 Nov 2009 13:40:30 +0100

On Fri, Nov 13, 2009 at 06:28:34PM +0800, Cheng-Yang Tang wrote:
> Hi,
>
> In a folder "test"
> if I add an empty file "foo" on version 11, and use "svn diff" to compare
> version 10 and 11:
> svn diff -r 10:11 showed that v11 has one file that does not exist in v10;
> but
> svn diff -r 11:10 failed to reveal this modification.
> the actuall results are as follows:
>
> louis@london:/tmp/svn-test/test$ svn diff -r 10:11 http://localhost/svn/test
> Index: foo
> ===================================================================
>
> louis@london:/tmp/svn-test/test$ svn diff -r 11:10 http://localhost/svn/test
> louis_at_london:/tmp/svn-test/test$
>
> Is this a bug or designed on purpose?

It's not on purpose, it just happens because the diff and merge
code share a lot of their code paths :(
So in some cases the code does things that make sense for merge but
not for diff, and this results in odd diff output.

See http://subversion.tigris.org/issues/show_bug.cgi?id=2333
which is a similar problem.

It's not trivial to fix with the current code, I've tried.
We may have to rewrite the diffing code and separate it from
the merge code to sort this out.

Stefan

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2417530

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-11-13 13:41:30 CET

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

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