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

Re: [PATCH] svnserve: write pid a bit earlier?

From: Eric Gillespie <epg_at_pretzelnet.org>
Date: 2007-10-13 10:06:26 CEST

Eric Gillespie <epg@pretzelnet.org> writes:

> "David Glasser" <glasser@davidglasser.net> writes:
>
> > svnserve -d -r bla --pid-file .svnserve-pid
> > spid=`cat .svnserve-pid`
> > run some tests
> > kill -9 $spid
>
> I don't object to your change, but all you do is shorten the
> race: it's inherent in the pidfile practice. What you want is:
>
> svnserve -d -r bla --foreground &
> spid=$!
> run some tests
> kill -9 $spid

Now that I think about it, I think your patch is broken. You
write the PID of the svnserve you started, but it then forks off
the one that hangs around. I have not tested this, or even
looked up apr_proc_detach, so I may be wrong.

-- 
Eric Gillespie <*> epg@pretzelnet.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Oct 13 10:06:34 2007

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.