 
> Looking at postmaster.c, my head started to spin a little. I think I 
> understood that exec case or not, by the time we get to BackendRun we 
> have already done all the fork/exec action. Have I read this correctly?

Yes. In the normal case, fork() then BackendRun. In the EXEC_BACKEND case,
fork/exec (or CreateProcess), which then invokes BackendRun via
SubPostmasterMain.


> (This code is getting rather intricate. A Readme file might be nice. 
Just a thought)

Which bits in particular?

Cheers,
Claudio

--- 
Certain disclaimers and policies apply to all email sent from Memetrics.
For the full text of these disclaimers and policies see 
<a
href="http://www.memetrics.com/emailpolicy.html">http://www.memetrics.com/em
ailpolicy.html</a>

Mon, 2 Feb 2004 10:11:43 +1100 
Claudio Natoli <claudio.natoli@memetrics.com>
Re: fork/exec
Claudio Natoli said:
>
>> Looking at postmaster.c, my head started to spin a little. I think I
>> understood that exec case or not, by the time we get to BackendRun we
>> have already done all the fork/exec action. Have I read this
>> correctly?
>
> Yes. In the normal case, fork() then BackendRun. In the EXEC_BACKEND
> case, fork/exec (or CreateProcess), which then invokes BackendRun via
> SubPostmasterMain.
>
>
>> (This code is getting rather intricate. A Readme file might be nice.
> Just a thought)
>
> Which bits in particular?
>

My concern was that I wanted to make sure that whatever I did was
available to the backend, and in the presence of exec/CreateProcess I
would need either to make sure it got passed to the backend if done
before, or to make sure that it was done after. That's why I wanted to
have the sequence of events clear in my head.

cheers

andrew



Sun, 1 Feb 2004 21:10:45 -0500 (EST)
"Andrew Dunstan" <andrew@dunslane.net>
Re: fork/exec