diff mercurial/sparse.py @ 48559:6bd42f9bc97e

merge: with stable
author Augie Fackler <augie@google.com>
date Tue, 04 Jan 2022 14:21:22 -0500
parents b74ee41addee
children a62ba3345534
line wrap: on
line diff
--- a/mercurial/sparse.py	Fri Feb 15 17:20:32 2019 -0500
+++ b/mercurial/sparse.py	Tue Jan 04 14:21:22 2022 -0500
@@ -718,7 +718,7 @@
 
     The new config is written out and a working directory refresh is performed.
     """
-    with repo.wlock(), repo.dirstate.parentchange():
+    with repo.wlock(), repo.lock(), repo.dirstate.parentchange():
         raw = repo.vfs.tryread(b'sparse')
         oldinclude, oldexclude, oldprofiles = parseconfig(
             repo.ui, raw, b'sparse'