op_lockfile.c File Reference

PID-based lockfile management. More...

#include "op_lockfile.h"
#include "op_file.h"
#include <errno.h>
#include <sys/types.h>
#include <stdio.h>
#include <signal.h>
#include <unistd.h>
Include dependency graph for op_lockfile.c:


int op_write_lock_file (char const *file)
 op_write_lock_file - write a lock file

Detailed Description

PID-based lockfile management.

Copyright 2002 OProfile authors
Read the file COPYING
John Levon
Philippe Elie

Function Documentation

int op_write_lock_file ( char const *  file  ) 

op_write_lock_file - write a lock file

errno on failure, or 0 on success

Write the pid into the given lock file. Stale lock files are detected and reset.

References op_file_readable(), and pid.

Referenced by main().

Generated on 29 Jul 2013 for oprofile by  doxygen 1.6.1