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

Re: [PATCH] fix crash when copying added files with --force

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: 2006-01-06 19:08:31 CET

Julian Foad wrote:
> Stefan Küng wrote:
>> The first crashreports for TortoiseSVN 1.3.0RC1 are coming in :)
>> When copying added (but not committed yet) files with the --force
>> flag, Subversion crashes in libsvn_wc/copy.c, line 515.
>> That's because there are (IMHO) bogus brackets in the check there.
>> Attached is a patch which fixes this issue.
> Are you sure? From my knowledge of C I can't see that removing those
> brackets can make any difference whatsoever.

Ok, I've got a recipe on how to provoke the crash.
Using svn version 1.3.0 (my own build, since the official windows
binaries aren't available yet):

$ cd some_working_copy
$ echo sometext > file
$ svn copy file file2
==> crash

The problem is that in line 526 of file libsvn_wc/copy.c, the
'src_entry' is NULL, so the 'if' check
if ((src_entry->repos ...
causes an exception.

I guess a fix would be quite easy, but I'm not sure if you'd rather have
a check for (src_entry != NULL && dst_entry != NULL) or if you'd like to
have the call to svn_wc_entry() in the line above to return an error.

May I also say that a fix for this is quite important: the RC1 release
of TSVN is out only for about a week, and I've already received 9
crashreports with exactly that crash. And considering it's an RC and the
first week of the year where many people are still on holiday, that's
quite a high number.


   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.tigris.org
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Jan 6 19:12:10 2006

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.