Function: lock-file
lock-file is a function defined in filelock.c.
Signature
(lock-file FILE)
Documentation
Lock FILE.
If the option create-lockfiles is nil, this does nothing.
Probably introduced at or before Emacs version 25.1.
Source Code
// Defined in /usr/src/emacs/src/filelock.c
{
#ifndef MSDOS
CHECK_STRING (file);
/* If the file name has special constructs in it,
call the corresponding file name handler. */
Lisp_Object handler;
handler = Ffind_file_name_handler (file, Qlock_file);
if (!NILP (handler))
return call2 (handler, Qlock_file, file);
lock_file (file);
#endif /* MSDOS */
return Qnil;
}