---
name: "pidfile"
section: "3abz"
platform: "linux"
package: "libabz0-dev"
version: "0.5.1"
release: "Debian 3.1 (Sarge)"
platforms: ["linux"]
url: "https://new.carta.tech/pidfile/3abz"
---

# pidfile(3abz)

create a file containing the process id of the current process.

## NAME

pidfile - create a file containing the process id of the current process.

## LIBRARIES

Abz Library (-labz), Debug Library (-ldebug)

## SYNOPSIS

```
#include <abz/pidfile.h>

int pidfile(const char *filename);
```

## DESCRIPTION

The **pidfile()** function creates a file containing the process id of the current process.

## RETURN VALUE

The **pidfile()** function returns 0 if successful, -1 if not.

Check *errno* to see what error occurred.

## NOTES

None of the libabz routines are thread-safe. I'm not planning to change this either! For more information, please see http://threading.2038bug.com/

## AUTHOR

Written by Abraham vd Merwe \<abz@blio.com\>
