Aggiornamento alla versione reale
[gapil.git] / listati / LockFile.c
1 #include <sys/types.h>
2 #include <sys/stat.h>
3 #include <unistd.h>    /* Unix standard functions */
4 /*
5  * Function LockFile:
6  */
7 int LockFile(const char* path_name)
8 {
9     return open(path_name, O_EXCL|O_CREAT);
10 }
11 /*
12  * Function UnlockFile:
13  */
14 int UnlockFile(const char* path_name) 
15 {
16     return unlink(path_name);
17 }