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

Re: ssh hangs using svn:// with svn-tunnel-agent = ssh *after* successful operation

From: Matt Kraai <kraai_at_alumni.cmu.edu>
Date: 2003-03-12 16:16:02 CET

On Wed, Mar 12, 2003 at 11:16:04AM +0100, PVM@capmon.dk wrote:
[snip description of breakage]

Mea culpa. This was fixed in revision 5280. Please apply the
following patch or wait for the next release.

Should we release a 0.19.1 which fixes this?

Matt

-- 
Oink!
Index: client.c
===================================================================
--- client.c	(revision 5279)
+++ client.c	(revision 5280)
@@ -335,16 +335,23 @@
       conn = svn_ra_svn_create_conn(NULL, proc->out, proc->in, pool);
       conn->proc = proc;
 
+      /* Wait for the process after closing the files by registering
+       * the process cleanup before the file ones, as they are
+       * executed in LIFO order.  */
+      apr_pool_cleanup_register(pool, proc, cleanup_process,
+                                apr_pool_cleanup_null);
+
       /* APR pipe objects don't have a child cleanup handler.  Set one
        * up so child processes don't hold open the tunnel agent's
        * input and output.  Unfortunately, the child cleanup handler
        * will flush the child process's write buffer (APR gives no way
        * to avoid that); this means we have to be careful not to leave
        * stuff lying around in the write buffer between ra_lib
-       * calls. */
+       * calls.
+       *
+       * Also close the files when the pool is destroyed.  */
       apr_pool_cleanup_register(pool, proc->in, cleanup_file, cleanup_file);
       apr_pool_cleanup_register(pool, proc->out, cleanup_file, cleanup_file);
-      apr_pool_cleanup_register(pool, proc, cleanup_process, apr_pool_cleanup_null);
     }
   else
     {
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Mar 12 16:15:45 2003

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.