Lines Matching refs:fn
56 fdlog_pipe_spawn (const char * const fn, const int rfd) in fdlog_pipe_spawn() argument
68 *(const char **)&args[2] = fn; in fdlog_pipe_spawn()
92 fdp->pid = fdlog_pipe_spawn(fdp->fdlog->fn, fdp->fd); in fdlog_pipe_restart()
164 fdlog_pipe_init (const char * const fn, const int fds[2], const pid_t pid) in fdlog_pipe_init() argument
173 return (fdp->fdlog = fdlog_init(fn, fds[1], FDLOG_PIPE)); in fdlog_pipe_init()
178 fdlog_pipe_open (const char * const fn) in fdlog_pipe_open() argument
182 if (0 != strcmp(fdlog->fn, fn)) continue; in fdlog_pipe_open()
190 pid_t pid = fdlog_pipe_spawn(fn, fds[0]); in fdlog_pipe_open()
194 return fdlog_pipe_init(fn, fds, pid); in fdlog_pipe_open()
207 fdlog_file_init (const char * const fn, const int fd) in fdlog_file_init() argument
212 return (fdlog_files.ptr[fdlog_files.used++] = fdlog_init(fn,fd,FDLOG_FILE)); in fdlog_file_init()
217 fdlog_file_open_fd (const char * const fn) in fdlog_file_open_fd() argument
220 return fdevent_open_cloexec(fn, 1, flags, 0644); /*(permit symlinks)*/ in fdlog_file_open_fd()
225 fdlog_file_open (const char * const fn) in fdlog_file_open() argument
229 if (0 != strcmp(fdlog->fn, fn)) continue; in fdlog_file_open()
233 int fd = fdlog_file_open_fd(fn); in fdlog_file_open()
234 return (-1 != fd) ? fdlog_file_init(fn, fd) : NULL; in fdlog_file_open()
239 fdlog_open (const char * const fn) in fdlog_open() argument
241 return (fn[0] != '|') in fdlog_open()
242 ? fdlog_file_open(fn) in fdlog_open()
243 : fdlog_pipe_open(fn+1); /*(skip the '|')*/ in fdlog_open()
258 "error flushing log %s", fdlog->fn); in fdlog_files_flush()
271 int fd = fdlog_file_open_fd(fdlog->fn); in fdlog_files_cycle()
280 "dup2() %s to %d", fdlog->fn, fdlog->fd); in fdlog_files_cycle()
286 "error cycling log %s", fdlog->fn); in fdlog_files_cycle()