"Fossies" - the Fresh Open Source Software Archive

Member "rpm-4.15.0/lib/rpmlock.h" (26 Jun 2019, 605 Bytes) of package /linux/misc/rpm-4.15.0.tar.bz2:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "rpmlock.h" see the Fossies "Dox" file reference documentation.

    1 #ifndef RPMLOCK_H
    2 #define RPMLOCK_H 
    3 
    4 #include <rpm/rpmutil.h>
    5 
    6 typedef struct rpmlock_s * rpmlock;
    7 
    8 enum {
    9     RPMLOCK_READ   = 1 << 0,
   10     RPMLOCK_WRITE  = 1 << 1,
   11     RPMLOCK_WAIT   = 1 << 2,
   12 };
   13 
   14 #ifdef __cplusplus
   15 extern "C" {
   16 #endif
   17 
   18 RPM_GNUC_INTERNAL
   19 rpmlock rpmlockNew(const char *lock_path, const char *descr);
   20 
   21 RPM_GNUC_INTERNAL
   22 rpmlock rpmlockNewAcquire(const char *lock_path, const char *descr);
   23 
   24 RPM_GNUC_INTERNAL
   25 int rpmlockAcquire(rpmlock lock);
   26 
   27 RPM_GNUC_INTERNAL
   28 void rpmlockRelease(rpmlock lock);
   29 
   30 RPM_GNUC_INTERNAL
   31 rpmlock rpmlockFree(rpmlock lock);
   32 
   33 #ifdef __cplusplus
   34 }
   35 #endif
   36 
   37 #endif