tryflock.c (176B)
1 /* ISC license. */ 2 3 #undef _POSIX_C_SOURCE 4 #undef _XOPEN_SOURCE 5 6 #include <sys/file.h> 7 #include <fcntl.h> 8 9 int main (void) 10 { 11 return flock(0, LOCK_EX | LOCK_UN | LOCK_NB) ; 12 }
skalibsMirror/fork of https://skarnet.org/software/skalibs/ | |
git clone https://ccx.te2000.cz/git/skalibs | |
Log | Files | Refs | README | LICENSE |