Documentation ¶
Overview ¶
Package lockutil contains utilities for building file locks.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateLockFile ¶
CreateLockFile writes information about the process that holds the lock to a temporary file having the specified name prefix in the specified directory. It returns the name of the temporary file.
func StillHeld ¶
StillHeld verifies if the given lock information corresponds to a running process. False positives are allowed (returning true when in fact the lock holder process no longer runs), but false negatives should be disallowed (returning false when in fact the lock holder still runs -- since that leads to poaching active locks).
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.