Molle Bestefich writes:
> Peter Samuelson wrote:
> > Molle Bestefich wrote:
> > > Try something like:
> > > (/usr/local/svn/hook-scripts/mailer.py commit "${REPOS}" "${REV}" &) &
> >
> > I thought that was only useful if your shell uses job control.
> > Noninteractive shells shouldn't.
>
> The purpose of the above is not to start the process in a background
> job but to detach it from the shell that runs it:
The problem in 1.3.0 is that the server reads the hooks stderr and
*then* waits for its child. It was changed from doing it the other way
around because that would deadlock when the hook wrote a lot to stderr
(causing the pipe to get full).
In 1.3.0, an extra write end to the stderr pipe was left open in the
child, meaning that if you redirect stderr when trunning the
background task, it would still inherit the write end of the
pipe,causing the server to block for input.
> ~ # (sleep 5 &) &
> [1] 416
> [1]+ Done ( sleep 5 & )
> ~ # jobs
> ~ # ps
> PID PPID STIME COMMAND
> 4084 4083 10:16 bash
> 2600 1 10:16 sleep
> 4092 4084 10:17 ps
> ~ #
Does this really make the problem go away?
Anyway, this is fixed in 1.3.1, but you still need to redirect (or
close, but that seems like a bad idea) stderr when running the
background job.
Thanks,
//Peter
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Mar 27 12:20:11 2006