summaryrefslogtreecommitdiff
path: root/src/lib/lockfile.c
Commit message (Collapse)AuthorAgeFilesLines
* lib: Set umask for file creation permissionsdimitri staessens2016-09-071-5/+4
| | | | | Permissions are now set correctly upon creation, removing the need to call fchmod.
* lib: Portability to FreeBSDdimitri staessens2016-07-291-2/+2
| | | | | | | | | | Various portability fixes for FreeBSD. POSIX requires shm file names to start with a "/" to be portable. lseek(2) can be undefined on POSIX shm, replaced with ftruncate(2). IRMd check on existing lockfile more portable. FreeBSD 11.0 is preferred as it natively supports robust mutexes. Full working LLC implementation pending.
* lib: Add lockfiledimitri staessens2016-07-071-0/+170
The pid of the IRMd is stored in a lockfile in shared memory. This makes checking if the IRMd is running independent of the configuration, as previously the IRMd pid was stored at the end of the shm_du_map, which could not be read by an IRMd that would be compiled with different configuration options. Also corrects some unnecessary includes Fixes #21.