Skip to main content

daemonize

Function daemonize 

Source
pub fn daemonize() -> Result<()>
Expand description

Fork twice, start a new session, move to /, and point the standard descriptors at /dev/null.

Returns only in the final grandchild; the intermediate processes call _exit(0).