Searched refs:pfh (Results 1 - 25 of 35) sorted by relevance

12

/freebsd-12-stable/lib/libutil/
H A Dpidfile.c57 static int _pidfile_remove(struct pidfh *pfh, int freeit);
60 pidfile_verify(const struct pidfh *pfh) argument
64 if (pfh == NULL || pfh->pf_fd == -1)
69 if (fstat(pfh->pf_fd, &sb) == -1)
71 if (sb.st_dev != pfh->pf_dev || sb.st_ino != pfh->pf_ino)
106 struct pidfh *pfh; local
112 pfh = malloc(sizeof(*pfh));
222 pidfile_write(struct pidfh *pfh) argument
262 pidfile_close(struct pidfh *pfh) argument
286 _pidfile_remove(struct pidfh *pfh, int freeit) argument
314 pidfile_remove(struct pidfh *pfh) argument
321 pidfile_fileno(const struct pidfh *pfh) argument
[all...]
/freebsd-12-stable/contrib/openbsm/compat/
H A Dpidfile.h51 static int _pidfile_remove(struct pidfh *pfh, int freeit);
54 pidfile_verify(const struct pidfh *pfh) argument
58 if (pfh == NULL || pfh->pf_fd == -1)
63 if (fstat(pfh->pf_fd, &sb) == -1)
65 if (sb.st_dev != pfh->pf_dev || sb.st_ino != pfh->pf_ino)
99 struct pidfh *pfh; local
110 pfh = malloc(sizeof(*pfh));
186 pidfile_write(struct pidfh *pfh) argument
226 pidfile_close(struct pidfh *pfh) argument
247 _pidfile_remove(struct pidfh *pfh, int freeit) argument
275 pidfile_remove(struct pidfh *pfh) argument
[all...]
/freebsd-12-stable/sys/net/
H A Dpfil.c102 struct packet_filter_hook *pfh; local
108 for (pfh = pfil_chain_get(dir, ph); pfh != NULL;
109 pfh = TAILQ_NEXT(pfh, pfil_chain)) {
110 if (pfh->pfil_func_flags != NULL) {
111 rv = (*pfh->pfil_func_flags)(pfh->pfil_arg, &m, ifp,
116 if (pfh->pfil_func != NULL) {
117 rv = (*pfh
236 struct packet_filter_hook *pfh, *pfnext; local
393 struct packet_filter_hook *pfh; local
422 struct packet_filter_hook *pfh; local
[all...]
/freebsd-12-stable/sbin/hastd/
H A Dhastd.h46 extern struct pidfh *pfh;
H A Dhastd.c74 struct pidfh *pfh; variable in typeref:struct:pidfh
138 (void)pidfile_close(pfh);
588 (void)pidfile_remove(pfh);
589 pfh = newpfh;
1132 KEEP_ERRNO((void)pidfile_remove(pfh));
1255 pfh = pidfile_open(cfg->hc_pidfile, 0600, &otherpid);
1256 if (pfh == NULL) {
1294 KEEP_ERRNO((void)pidfile_remove(pfh));
1301 KEEP_ERRNO((void)pidfile_remove(pfh));
1309 KEEP_ERRNO((void)pidfile_remove(pfh));
[all...]
/freebsd-12-stable/usr.sbin/bluetooth/btpand/
H A Dtap.c123 chan->pfh = pidfile_open(pidfile, 0600, NULL);
124 if (chan->pfh == NULL)
126 else if (pidfile_write(chan->pfh) < 0) {
128 pidfile_remove(chan->pfh);
129 chan->pfh = NULL;
H A Dchannel.c140 if (chan->pfh != NULL) {
141 pidfile_remove(chan->pfh);
142 chan->pfh = NULL;
H A Dbtpand.h111 struct pidfh *pfh; member in struct:channel
/freebsd-12-stable/usr.sbin/daemon/
H A Ddaemon.c88 struct pidfh *ppfh, *pfh; local
179 ppfh = pfh = NULL;
184 open_pid_files(pidfile, ppidfile, &pfh, &ppfh);
280 pidfile_write(pfh);
379 pidfile_remove(pfh);
397 struct pidfh **pfh, struct pidfh **ppfh)
403 *pfh = pidfile_open(pidfile, 0600, &fpid);
404 if (*pfh == NULL) {
417 pidfile_remove(*pfh);
396 open_pid_files(const char *pidfile, const char *ppidfile, struct pidfh **pfh, struct pidfh **ppfh) argument
/freebsd-12-stable/cddl/compat/opensolaris/misc/
H A Dfsshare.c50 struct pidfh *pfh; local
53 pfh = pidfile_open(_PATH_MOUNTDPID, 0600, &mountdpid);
54 if (pfh != NULL) {
56 pidfile_remove(pfh);
/freebsd-12-stable/lib/libutil/tests/
H A Dpidfile_test.c273 struct pidfh *pfh; local
281 pfh = pidfile_open(path, 0600, NULL);
282 if (pfh == NULL)
284 if (pidfile_write(pfh) != 0)
295 if (pidfile_close(pfh) != 0)
/freebsd-12-stable/contrib/openbsm/bin/auditdistd/
H A Dauditdistd.c89 struct pidfh *pfh; variable in typeref:struct:pidfh
119 (void)pidfile_close(pfh);
548 KEEP_ERRNO((void)pidfile_remove(pfh));
725 pfh = NULL;
727 pfh = pidfile_open(adcfg->adc_pidfile, 0600, &otherpid);
728 if (pfh == NULL) {
767 KEEP_ERRNO((void)pidfile_remove(pfh));
775 KEEP_ERRNO((void)pidfile_remove(pfh));
782 if (pfh != NULL) {
784 if (pidfile_write(pfh) <
[all...]
H A Dauditdistd.h275 extern struct pidfh *pfh;
/freebsd-12-stable/usr.sbin/watchdogd/
H A Dwatchdogd.c123 struct pidfh *pfh; local
147 pfh = pidfile_open(pidfile, 0600, &otherpid);
148 if (pfh == NULL) {
159 pidfile_remove(pfh);
167 pidfile_write(pfh);
176 pidfile_remove(pfh);
/freebsd-12-stable/usr.sbin/cron/cron/
H A Dcron.c55 struct pidfh *pfh; variable in typeref:struct:pidfh
85 pfh = pidfile_open(pidfile, 0600, &otherpid);
86 if (pfh == NULL) {
143 pidfile_remove(pfh);
152 pidfile_write(pfh);
/freebsd-12-stable/usr.sbin/rtsold/
H A Drtsold.c104 static struct pidfh *pfh; variable in typeref:struct:pidfh
208 pfh = pidfile_open(pidfilepath, 0644, NULL);
209 if (pfh == NULL)
270 if (pfh != NULL && pidfile_write(pfh) != 0) {
286 if (pfh != NULL)
287 pidfile_remove(pfh);
/freebsd-12-stable/usr.sbin/powerd/
H A Dpowerd.c492 struct pidfh *pfh = NULL; local
609 pfh = pidfile_open(pidfile, 0600, &otherpid);
610 if (pfh == NULL) {
619 pidfile_remove(pfh);
623 pidfile_write(pfh);
842 pidfile_remove(pfh);
/freebsd-12-stable/sys/netpfil/ipfw/
H A Dip_fw_pfil.c541 struct pfil_head *pfh; local
544 pfh = pfil_head_get(PFIL_TYPE_AF, pf);
545 if (pfh == NULL)
551 (hook_func, NULL, PFIL_IN | PFIL_OUT | PFIL_WAITOK, pfh); local
/freebsd-12-stable/contrib/wpa/src/utils/
H A Dos_unix.c234 struct pidfh *pfh;
236 pfh = pidfile_open(pid_file, 0600, &otherpid);
237 if (pfh == NULL) {
249 pidfile_remove(pfh);
263 pidfile_write(pfh);
/freebsd-12-stable/usr.sbin/uhsoctl/
H A Duhsoctl.c111 struct pidfh *pfh; member in struct:ctx
1292 struct pidfh *pfh; local
1297 pfh = pidfile_open(ctx->pidfile, 0600, &opid);
1298 if (pfh == NULL) {
1305 pidfile_remove(pfh);
1309 pidfile_write(pfh);
1310 ctx->pfh = pfh;
1557 pidfile_remove(ctx.pfh);
/freebsd-12-stable/sbin/devd/
H A Ddevd.cc149 static struct pidfh *pfh; variable in typeref:struct:pidfh
527 pfh = pidfile_open(_pidfile.c_str(), 0600, &otherpid);
528 if (pfh == NULL) {
539 pidfile_write(pfh);
546 pidfile_close(pfh);
553 pidfile_remove(pfh);
/freebsd-12-stable/tools/tools/net80211/wesside/wesside/
H A Dwesside.c2401 struct pcap_file_header pfh; local
2403 memset(&pfh, 0, sizeof(pfh));
2404 pfh.magic = TCPDUMP_MAGIC;
2405 pfh.version_major = PCAP_VERSION_MAJOR;
2406 pfh.version_minor = PCAP_VERSION_MINOR;
2407 pfh.thiszone = 0;
2408 pfh.sigfigs = 0;
2409 pfh.snaplen = 65535;
2410 pfh
[all...]
/freebsd-12-stable/libexec/tftpd/tests/
H A Dfunctional.c299 struct pidfh *pfh; local
333 pfh = pidfile_open(pidfile, 0644, NULL);
334 ATF_REQUIRE_MSG(pfh != NULL,
336 ATF_REQUIRE_EQ(pidfile_write(pfh), 0);
337 ATF_REQUIRE_EQ(pidfile_close(pfh), 0);
/freebsd-12-stable/sbin/ggate/ggated/
H A Dggated.c967 struct pidfh *pfh; local
1025 pfh = pidfile_open(ggated_pidfile, 0600, &otherpid);
1026 if (pfh == NULL) {
1040 pidfile_write(pfh);
1078 pidfile_remove(pfh);
/freebsd-12-stable/sbin/mount/
H A Dmount.c228 struct pidfh *pfh; local
232 pfh = pidfile_open(_PATH_MOUNTDPID, 0600, &mountdpid);
233 if (pfh != NULL) {
235 pidfile_remove(pfh);

Completed in 412 milliseconds

12