Hook scripts start with an empty environment instead of inheriting it
from svnserve or whatever.

This is inconvenient, not least for the case where you want to commit
something to an svn+ssh server via a local pushmi mirror on file:/// and
your SSH_AUTH_SOCK is lost so you have to type your passphrase all the time.

There's no comment in the code explaining why the environment has to be
empty, so I assume it was just done like that on a whim. Trivial patch
attached.

-- Tim Starling
Index: subversion/libsvn_repos/hooks.c
===================================================================
--- subversion/libsvn_repos/hooks.c	(revision 926936)
+++ subversion/libsvn_repos/hooks.c	(working copy)
@@ -238,7 +238,7 @@
             (apr_err, _("Can't create null stdout for hook '%s'"), cmd);
     }
 
-  err = svn_io_start_cmd(&cmd_proc, ".", cmd, args, FALSE,
+  err = svn_io_start_cmd(&cmd_proc, ".", cmd, args, TRUE,
                          stdin_handle, result ? write_outhandle : null_handle,
                          write_errhandle, pool);
 

Reply via email to