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

Re: "svn diff -rN" dereferences a NIL pointer and crashes with "Segmentation fault".

From: Garrett Rooney <rooneg_at_electricjellyfish.net>
Date: 2006-02-17 22:54:35 CET

On 2/17/06, Garrett Rooney <rooneg@electricjellyfish.net> wrote:

> Ahh, it was the nonrecursive checkout that was throwing me. Thanks
> for the recipie, I'll look into fixing this...

Ok, so here's a "fix" for the bug. I'm totally not sure this is the
right thing to do, but due to the incredible suck of nonrecursive
checkouts, I can't figure out a better way around it. When you check
out a directory nonrecursively, the child directories in it don't even
show up in .svn/entries, so when we call svn_wc_entry looking for one
of them, we get nothing back. Of course, we can't tell that's why we
didn't get anything back, because there's no way to determine that
this was a nonrecursive checkout. Sigh.

In an ideal world, nonrecursive checkouts would leave some indication
that the directory in question exists, so we could check for this sort
of case, but we don't live in an ideal world...

I'm also kind of curious what the "right" behavior is. Do we just
skip over the missing directory? That's what I've done here, but I'm
not convinced it's correct.

Anyway, here's a patch, I'd love it if someone else could confirm that
this is the only solution currently available. I'll probably add an
actual test for this before committing it.

-garrett

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

Received on Fri Feb 17 22:55:19 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.