|
@@ -42,7 +42,7 @@ open Core.Std;;
|
|
|
type lock_status =
|
|
|
Locked
|
|
|
| Free
|
|
|
- | Error
|
|
|
+ | Err
|
|
|
;;
|
|
|
(* Name of the lock file *)
|
|
|
(* TODO Put it in Const *)
|
|
@@ -59,7 +59,7 @@ let status () =
|
|
|
match Sys.file_exists lock_name with
|
|
|
`Yes -> Locked
|
|
|
| `No -> Free
|
|
|
- | `Unknown -> Error
|
|
|
+ | `Unknown -> Err
|
|
|
;;
|
|
|
|
|
|
(* Remove the lock file *)
|
|
@@ -85,7 +85,7 @@ let wait ?(until=10) ?(delay=1) () =
|
|
|
else
|
|
|
None
|
|
|
| Free -> Some (lock ())
|
|
|
- | Error -> failwith "Problem with lock file"
|
|
|
+ | Err -> failwith "Problem with lock file"
|
|
|
in
|
|
|
wait_loop 0
|
|
|
|> (function
|