smbd as a daemon
Jeremy Allison
jra at samba.org
Tue Mar 25 13:38:57 MDT 2014
On Tue, Mar 25, 2014 at 09:28:34PM +0200, Alexander Bokovoy wrote:
> >
> > Ok, attached patch compiles for me and links libsystem-daemon
> > properly. I'm going to run some package tests tomorrow.
> Updated patch -- I forgot one define for non-systemd case and also
> added changes to systemd services.
Few comments inline.
> Become a daemon, discarding the controlling terminal.
> ****************************************************************************/
>
> -_PUBLIC_ void become_daemon(bool do_fork, bool no_process_group, bool log_stdout)
> +_PUBLIC_ void become_daemon(bool do_fork, bool no_process_group, bool log_stdout, bool wait_for_child_init)
What is the extra parameter 'bool wait_for_child_init' for ?
In the calling code you're always passing it as 'true' so
what does it achieve ?
Under what circumstances do we *not* want to do this ?
I think you should just remove it.
> - become_daemon(Fork, no_process_group, log_stdout);
> + become_daemon(Fork, no_process_group, log_stdout, True);
Bah. We don't use 'True' anymore. If you do end up
keeping the parameter please use 'true/false' in all
new code.
Otherwise looks ok to me.
Jeremy.
More information about the samba-technical
mailing list