daemon: Factor out code into new function fork_and_wait_for_startup().
[openvswitch] / lib / daemon.h
index eb38d5d87971aa3d222a385ec352640520d21a08..63b64b99f0b8ee3714718e55a070a5e6fed8924e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2008, 2009, 2010, 2011 Nicira Networks.
+ * Copyright (c) 2008, 2009, 2010, 2011, 2012 Nicira, Inc.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -64,6 +64,7 @@ bool is_chdir_enabled(void);
 void set_detach(void);
 bool get_detach(void);
 void daemon_set_monitor(void);
+void daemon_save_fd(int fd);
 void daemonize(void);
 void daemonize_start(void);
 void daemonize_complete(void);
@@ -72,4 +73,6 @@ void daemon_usage(void);
 pid_t read_pidfile(const char *name);
 pid_t read_pidfile_if_exists(const char *name);
 
+pid_t fork_and_clean_up(void);
+
 #endif /* daemon.h */