Index: lib/libutil/pidfile.c =================================================================== --- lib/libutil/pidfile.c (wersja 229992) +++ lib/libutil/pidfile.c (kopia robocza) @@ -41,6 +41,14 @@ #include #include +/* for pidfile.c */ +struct pidfh { + int pf_fd; + char pf_path[MAXPATHLEN + 1]; + __dev_t pf_dev; + ino_t pf_ino; +}; + static int _pidfile_remove(struct pidfh *pfh, int freeit); static int Index: lib/libutil/pidfile.3 =================================================================== --- lib/libutil/pidfile.3 (wersja 229992) +++ lib/libutil/pidfile.3 (kopia robocza) @@ -36,7 +36,6 @@ .Sh LIBRARY .Lb libutil .Sh SYNOPSIS -.In sys/param.h .In libutil.h .Ft "struct pidfh *" .Fn pidfile_open "const char *path" "mode_t mode" "pid_t *pidptr" Index: lib/libutil/libutil.h =================================================================== --- lib/libutil/libutil.h (wersja 229992) +++ lib/libutil/libutil.h (kopia robocza) @@ -48,6 +48,11 @@ #define _GID_T_DECLARED #endif +#ifndef _MODE_T_DECLARED +typedef __mode_t mode_t; +#define _MODE_T_DECLARED +#endif + #ifndef _PID_T_DECLARED typedef __pid_t pid_t; #define _PID_T_DECLARED @@ -73,21 +78,12 @@ char *value; } *properties; -#ifdef _SYS_PARAM_H_ -/* for pidfile.c */ -struct pidfh { - int pf_fd; - char pf_path[MAXPATHLEN + 1]; - __dev_t pf_dev; - ino_t pf_ino; -}; -#endif - /* Avoid pulling in all the include files for no need */ struct in_addr; struct kinfo_file; struct kinfo_proc; struct kinfo_vmentry; +struct pidfh; struct sockaddr; struct termios; struct winsize; @@ -167,14 +163,12 @@ int gr_tmp(int _mdf); #endif -#ifdef _SYS_PARAM_H_ int pidfile_close(struct pidfh *_pfh); int pidfile_fileno(const struct pidfh *_pfh); struct pidfh * pidfile_open(const char *_path, mode_t _mode, pid_t *_pidptr); int pidfile_remove(struct pidfh *_pfh); int pidfile_write(struct pidfh *_pfh); -#endif #ifdef _UFS_UFS_QUOTA_H_ struct fstab;