/usr/lib/s9fes/help/sys_lock is in scheme9 2010.11.13-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 | S9 EXT (sys:lock string) ==> boolean
Create a lock file named (string-append STRING ".lock"). If
the file already exists when the function is called, return
#F, indicating that the requested resource is already locked.
Otherwise return #T. SYS:LOCK uses mkdir() to create the
lock file, which is atomic on virtually all systems.
(sys:unlock "foo")
(list (sys:lock "foo")
(sys:lock "foo")) ==> (#t #f)
|