mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-25 16:13:17 +00:00
Catch write-lock attempts immediately if running in read-only mode rather
than depending on getting a write fail.
This commit is contained in:
parent
484aca02e2
commit
e7905b1443
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=25867
@ -319,6 +319,11 @@ Writer_Lock (list)
|
||||
if (noexec)
|
||||
return (0);
|
||||
|
||||
if (readonlyfs) {
|
||||
error (0, 0, "write lock failed - read-only repository");
|
||||
return (1);
|
||||
}
|
||||
|
||||
/* We only know how to do one list at a time */
|
||||
if (locklist != (List *) NULL)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user