aboutgitcodebugslistschat
path: root/util.h
diff options
context:
space:
mode:
authorStefano Brivio <sbrivio@redhat.com>2024-05-22 19:50:58 +0200
committerStefano Brivio <sbrivio@redhat.com>2024-05-23 16:43:13 +0200
commitba23b05545e1e316235fad7a66f3cfd643c22146 (patch)
treecd590216a2fab87eea2f109ed28eadb16a551a9e /util.h
parent57d8aa8ffefcc226c5c3179e4a8d346cbe61e865 (diff)
downloadpasst-ba23b05545e1e316235fad7a66f3cfd643c22146.tar
passt-ba23b05545e1e316235fad7a66f3cfd643c22146.tar.gz
passt-ba23b05545e1e316235fad7a66f3cfd643c22146.tar.bz2
passt-ba23b05545e1e316235fad7a66f3cfd643c22146.tar.lz
passt-ba23b05545e1e316235fad7a66f3cfd643c22146.tar.xz
passt-ba23b05545e1e316235fad7a66f3cfd643c22146.tar.zst
passt-ba23b05545e1e316235fad7a66f3cfd643c22146.zip
passt, util: Move opening of PID file to its own function
We won't call it from main() any longer: move it. Signed-off-by: Stefano Brivio <sbrivio@redhat.com> Reviewed-by: Richard W.M. Jones <rjones@redhat.com>
Diffstat (limited to 'util.h')
-rw-r--r--util.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/util.h b/util.h
index 6fa8df2..aa6e4b4 100644
--- a/util.h
+++ b/util.h
@@ -156,6 +156,7 @@ char *line_read(char *buf, size_t len, int fd);
void ns_enter(const struct ctx *c);
bool ns_is_init(void);
int open_in_ns(const struct ctx *c, const char *path, int flags);
+int pidfile_open(const char *path);
void pidfile_write(int fd, pid_t pid);
int __daemon(int pidfile_fd, int devnull_fd);
int fls(unsigned long x);