Subject: Re: bug#21559: additional patch needed to setGIT_OPTIONAL_LOCKS=0 in all cases

From: Phil Sainty <[email-masked]>
Date: Wed, 26 Sep 2018 15:16:50 +1200

On 2018-09-26 00:23, Andrew Ruder wrote:
> Please see attached patch.  There is also some early reports of
> success at https://github.com/magit/magit/issues/2708

Just to reiterate my comments from there, I believe this new patch
does indeed resolve this bug.

I've been using Emacs 26.1 with the earlier patch applied:
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=21559#131
And git version 2.16.3

With that, I was very regularly encountering the error "Unable to
create '.git/index.lock': File exists." when rebasing in Magit with
global-auto-revert-mode enabled.

With this new patch applied too, I am not seeing the error at all.

For testing I repeatedly rebased a moderately large branch, with and
without the new patch (3 times each).  Without the new patch I was
encountering "Unable to create '.git/index.lock': File exists."
between 3 and 5 times during each rebase.  With the new patch I didn't
encounter the problem at all in any of the rebases.

-Phil