00001 /** 00002 * @file op_lockfile.h 00003 * PID-based lockfile management 00004 * 00005 * @remark Copyright 2002 OProfile authors 00006 * @remark Read the file COPYING 00007 * 00008 * @author John Levon 00009 * @author Philippe Elie 00010 */ 00011 00012 #ifndef OP_LOCKFILE_H 00013 #define OP_LOCKFILE_H 00014 00015 #ifdef __cplusplus 00016 extern "C" { 00017 #endif 00018 00019 #include <sys/types.h> 00020 00021 /** 00022 * op_write_lock_file - write a lock file 00023 * \return errno on failure, or 0 on success 00024 * 00025 * Write the pid into the given lock file. Stale 00026 * lock files are detected and reset. 00027 */ 00028 int op_write_lock_file(char const * file); 00029 00030 #ifdef __cplusplus 00031 } 00032 #endif 00033 00034 #endif /* OP_LOCKFILE_H */
1.6.1