mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-22 10:26:20 +00:00
(main): Increase lock timeout to five minutes.
This commit is contained in:
parent
238959e902
commit
66a8ad0fd4
@ -251,11 +251,14 @@ main (argc, argv)
|
||||
break;
|
||||
sleep (1);
|
||||
|
||||
/* If lock file is a minute old, unlock it. */
|
||||
/* If lock file is five minutes old, unlock it.
|
||||
Five minutes should be good enough to cope with crashes
|
||||
and wedgitude, and long enough to avoid being fooled
|
||||
by time differences between machines. */
|
||||
if (stat (lockname, &st) >= 0)
|
||||
{
|
||||
now = time (0);
|
||||
if (st.st_ctime < now - 60)
|
||||
if (st.st_ctime < now - 300)
|
||||
unlink (lockname);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user