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

svn 1.6.4 bug yields a working copy with missing data

From: Vincent Lefevre <vincent+svn_at_vinc17.org>
Date: Wed, 12 Aug 2009 18:16:42 +0200

Hi,

Another nasty bug in Subversion that leads to a working copy
with missing data and an inconsistent state...

To reproduce it, consider the following script (run it from
an empty directory):

----------------------------------------
#!/bin/sh

set -ex

svnadmin create svn
svn co file://`pwd`/svn wc1
cd wc1
touch foo
svn add foo
svn ci -m 'added foo'
svn cp foo bar
echo blah >> bar
svn ci -m 'foo -> bar'
cd ..
svn co file://`pwd`/svn_at_1 wc2
cd wc2
svn cp foo bar
svn up
svn resolved bar
svn revert bar
svn up
svn st -u
svn ls -v
ls -l
----------------------------------------

Here's the output:

+ svnadmin create svn
++ pwd
+ svn co file:///home/vlefevre/tmp/test/svn wc1
Checked out revision 0.
+ cd wc1
+ touch foo
+ svn add foo
A foo
+ svn ci -m 'added foo'
Adding foo
Transmitting file data .
Committed revision 1.
+ svn cp foo bar
A bar
+ echo blah
+ svn ci -m 'foo -> bar'
Adding bar
Transmitting file data .
Committed revision 2.
+ cd ..
++ pwd
+ svn co file:///home/vlefevre/tmp/test/svn_at_1 wc2
A wc2/foo
Checked out revision 1.
+ cd wc2
+ svn cp foo bar
A bar
+ svn up
   C bar
At revision 2.
Summary of conflicts:
  Tree conflicts: 1
+ svn resolved bar
Resolved conflicted state of 'bar'
+ svn revert bar
Reverted 'bar'
+ svn up
At revision 2.
+ svn st -u
? bar
Status against revision: 2
+ svn ls -v
      2 vlefevre Aug 12 18:02 ./
      2 vlefevre 5 Aug 12 18:02 bar
      1 vlefevre 0 Aug 12 18:02 foo
+ ls -l
total 0
-rw-r--r-- 1 vlefevre vlefevre 0 2009-08-12 18:02:40 bar
-rw-r--r-- 1 vlefevre vlefevre 0 2009-08-12 18:02:39 foo

As you can see, the working copy is declared to be up-to-date,
but its contents don't match those of the repository.

This bug occurs with:

svn, version 1.6.4 (r38063)
   compiled Aug 6 2009, 20:17:47

-- 
Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/>
100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/>
Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2382938
Received on 2009-08-12 18:17:01 CEST

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.