airlock.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00022
00023 #ifndef _AIR_AIRLOCK_H_
00024 #define _AIR_AIRLOCK_H_
00025
00026 #include <airframe/autoinc.h>
00027
00029 #define LOCK_ERROR_DOMAIN g_quark_from_string("airframeLockError")
00030
00033 #define LOCK_ERROR_LOCK 1
00034
00039 typedef struct _AirLock {
00041 GString *lpath;
00043 int lfd;
00045 gboolean held;
00046 } AirLock;
00047
00049 #define AIR_LOCK_INIT { NULL, 0, FALSE }
00050
00060 gboolean air_lock_acquire(
00061 AirLock *lock,
00062 const char *path,
00063 GError **err);
00064
00070 void air_lock_release(
00071 AirLock *lock);
00072
00079 void air_lock_cleanup(
00080 AirLock *lock);
00081
00082
00083 #endif