diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2024-05-03 20:43:37 +0000 |
---|---|---|
committer | Laurent Bercot <ska@appnovation.com> | 2024-05-03 20:43:37 +0000 |
commit | 6d0c114f57bcd554383a41c9ca791e25e95b81b5 (patch) | |
tree | 7ed5e04fa40a18c9e7d1858ae073b9ef602faa3b /src/libs6/ftrig1_make.c | |
parent | 35709f34aaafad99c89d9848b68e3d211b7e0f02 (diff) | |
download | s6-6d0c114f57bcd554383a41c9ca791e25e95b81b5.tar.xz |
Restore cleanups in s6-ftrigrd; fix an old bug and a new bug
ftrigw_clean() didn't clean properly.
ftrig1_make() didn't give enough perms to the fifo, notification
could fail in certain cases.
Signed-off-by: Laurent Bercot <ska@appnovation.com>
Diffstat (limited to 'src/libs6/ftrig1_make.c')
-rw-r--r-- | src/libs6/ftrig1_make.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libs6/ftrig1_make.c b/src/libs6/ftrig1_make.c index 04c8c73..5c38e4b 100644 --- a/src/libs6/ftrig1_make.c +++ b/src/libs6/ftrig1_make.c @@ -23,7 +23,7 @@ int ftrig1_make (ftrig1_t *f, char const *path) tmp[pathlen + 2 + FTRIG1_PREFIXLEN] = ':' ; if (!timestamp(tmp + pathlen + 3 + FTRIG1_PREFIXLEN)) return 0 ; memcpy(tmp + pathlen + FTRIG1_PREFIXLEN + 28, ":XXXXXX", 8) ; - ff.fd = mkptemp2(tmp, O_NONBLOCK|O_CLOEXEC) ; + ff.fd = mkptemp3(tmp, 0622, O_NONBLOCK|O_CLOEXEC) ; if (ff.fd == -1) return 0 ; ff.fdw = open_write(tmp) ; if (ff.fdw == -1) goto err1 ; |