[PATCH] git-svn: fix blocking with svn:// servers after do_switch

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We now explicitly disconnect before starting new SVN::Ra
connections.  SVN::Ra objects will automatically be disconnected
from the server on DESTROY.

SVN servers seem to have problems accepting multiple connections
from one client, and the SVN library has trouble being connected
to multiple servers at once.  This appears to cause opening the
second connection to block, and cause git-svn to be unusable
after using the do_switch() function.

git-svn opens another connection because a workaround is
necesary for the buggy reparent function handling on certain
versions of svn:// and svn+ssh:// servers.  Instead of using the
reparent function (analogous to chdir), it will reopen a new
connection to a different URL on the SVN server.

Signed-off-by: Eric Wong <normalperson@xxxxxxxx>
---

  Gerrit Pape <pape@xxxxxxxxxxx> wrote:
  > Hi, on Debian unstable the current version of libsvn-perl is 1.4.4dfsg1.
  > With this version git-svn uses do_switch instead of do_update, which
  > seems to not work properly, please see
  > 
  >  http://bugs.debian.org/430091
  > 
  > on how to reproduce the problem.  The following also is showing a
  > problem, as it blocks in read() after do_switch
  > 
  >  git svn clone -T trunk -b branches -t tags \
  >    svn://bruce-guenter.dyndns.org/bglibs
  > 
  > I'm not sure whether this is a git-svn or a subversion problem, thanks
  > for your input.

  Thanks for the bug report.  Sorry for the latency these days, I've
  been quite busy with other things.

  Although this fixes blocking reads, this does *not* fix the
  "Malformed network data" issue, which has been around for a
  while...

  I'll try to find time to fix the "Malformed network data" bug
  in a few days time, but it's not fatal (just restart git-svn,
  this error happens at a point where it's not possible to have
  a corrupted import).

 git-svn.perl |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/git-svn.perl b/git-svn.perl
index 51979f9..b3dffcc 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -3002,6 +3002,7 @@ sub new {
 	      \&Git::SVN::Prompt::username, 2),
 	  ]);
 	my $config = SVN::Core::config_get_config($config_dir);
+	$RA = undef;
 	my $self = SVN::Ra->new(url => $url, auth => $baton,
 	                      config => $config,
 			      pool => SVN::Pool->new,
-- 
Eric Wong
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux