History log of /freebsd-current/lib/libutil/pidfile.3
Revision Date Author Comments
# fa9896e0 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: two-line nroff pattern

Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/


# bc89b58d 13-Jun-2020 Gordon Bergling <gbe@FreeBSD.org>

libutil: Document function HISTORY within the manpages

Reviewed by: bcr (mentor)
Approved by: bcr (mentor)
MFC after: 7 days
Differential Revision: https://reviews.freebsd.org/D24795


# 872a3a62 18-May-2016 Pedro F. Giffuni <pfg@FreeBSD.org>

libutil: minor spelling fixes.


# 2b7af31c 23-Jun-2014 Baptiste Daroussin <bapt@FreeBSD.org>

use .Mt to mark up email addresses consistently (part3)

PR: 191174
Submitted by: Franco Fichtner <franco at lastsummer.de>


# cc1ddd46 08-Feb-2012 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Add a comment to the example that pidfile_* functions can handle pfh being NULL.

MFC after: 3 days


# 7f8d054f 08-Feb-2012 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Note that calling pidfile_write(3) multiple times is fine.

MFC after: 3 days


# 5c005f00 16-Jan-2012 Guy Helmer <ghelmer@FreeBSD.org>

Remove unnecessary includes from these libutil man pages.

Requested by bde (as was the previous commit).


# 50636e13 12-Jan-2012 Guy Helmer <ghelmer@FreeBSD.org>

pidfile_open() no longer uses fcntl() to set the close-on-exec flag.


# 4a25aa06 10-Jan-2012 Guy Helmer <ghelmer@FreeBSD.org>

Style fixes courtesy of pjd.


# 719060e9 10-Jan-2012 Guy Helmer <ghelmer@FreeBSD.org>

Document that pidfile_open() now sets the FD_CLOEXEC flag on the open
file descriptor, and that errors can be returned as a result of the
fcntl(2) system call.


# f295618d 10-Jan-2012 Guy Helmer <ghelmer@FreeBSD.org>

Add pidfile_fileno() to obtain the file descriptor for an open
pidfile.


# e8cc80c0 16-Oct-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

In pidfile_open(), if the pidfile is locked, but empty (PID is not stored yet)
and the caller requested other process' PID by passing non-NULL pidptr
argument, we will wait at most 100ms for the PID to show up in the file and if
it won't, we will store -1 in *pidptr.

From now on, pidfile_open() function never sets errno to EAGAIN on failure.

In collaboration with: des
MFC after: 1 week


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# a27c52a9 06-Jun-2009 Dag-Erling Smørgrav <des@FreeBSD.org>

Add missing .Pp


# cb7cd07a 20-Oct-2008 Dag-Erling Smørgrav <des@FreeBSD.org>

pidfile(3) uses flopen(3) - don't make any assumptions about how the
latter is implemented.


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# 3dca0939 13-Oct-2007 Simon L. B. Nielsen <simon@FreeBSD.org>

Minor mdoc cleanup: Every sentence should start on its own line.


# fefc6803 12-Oct-2007 Konstantin Belousov <kib@FreeBSD.org>

When pidfile is already locked and has zero length, do not return
success and zero pid from pidfile_read(). Return EAGAIN instead. Sleep
up to three times for 5 ms while waiting for pidfile to be written.

mount(8) does the kill(mountpid, SIGHUP). If mountd pidfile is truncated,
that would result in the SIGHUP delivered to the mount' process group
instead of the mountd.

Found and analyzed by: Peter Holm
Tested by: Peter Holm, kris
Reviewed by: pjd
MFC after: 1 week


# ef608a60 04-Mar-2006 Giorgos Keramidas <keramida@FreeBSD.org>

Use `intmax_t' instead of plain `int' for pid_t casts.

Useful tips from: ru, bde
Approved by: pjd
MFC after: 3 days


# 560c4fc1 28-Jan-2006 Pawel Jakub Dawidek <pjd@FreeBSD.org>

- Add a note that passing NULL to pidfile_write(), pidfile_remove() and
pidfile_close() functions is safe. This possibility is used in example code.
- Cast pid_t to int.

Requested by: yar


# 6b84cd58 18-Nov-2005 Ruslan Ermilov <ru@FreeBSD.org>

Fix markup, grammar and spelling.


# 8b28aef2 16-Sep-2005 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Pidfiles should be created with permission preventing users from opening
them for reading. When user can open file for reading, he can also
flock(2) it, which can lead to confusions.

Pointed out by: green


# 412fa8f1 24-Aug-2005 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Add a family of functions for reliable pidfiles handling.

Idea from: jmg
Discussed on: arch@