GNU bug report logs -
#21457
25.0.50; vc-test-git03-working-revision test fails
Previous Next
Reported by: Eli Zaretskii <eliz <at> gnu.org>
Date: Fri, 11 Sep 2015 07:52:02 UTC
Severity: normal
Found in version 25.0.50
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #20 received at 21457 <at> debbugs.gnu.org (full text, mbox):
> From: Andreas Schwab <schwab <at> linux-m68k.org>
> Cc: Glenn Morris <rgm <at> gnu.org>, 21457 <at> debbugs.gnu.org
> Date: Sat, 12 Sep 2015 11:42:59 +0200
>
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
> > The patches below make this work for me. The first one should
> > probably be applied regardless, as without it vc-git--rev-parse is not
> > safe to call in some borderline cases.
> >
> > diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el
> > index 8a0f554..af2b39f 100644
> > --- a/lisp/vc/vc-git.el
> > +++ b/lisp/vc/vc-git.el
> > @@ -1137,7 +1137,9 @@ (defun vc-git--rev-parse (rev)
> > (with-temp-buffer
> > (and
> > (vc-git--out-ok "rev-parse" rev)
> > - (buffer-substring-no-properties (point-min) (+ (point-min) 40)))))
> > + (buffer-substring-no-properties (point-min)
> > + (min (1- (point-max))
> > + (+ (point-min) 40))))))
>
> Why does vc-git--out-ok return true when git rev-parse failed?
Good question, I will look into it soon.
Do you know whether "HEAD" is indeed what the latest Git should return
in this case, though? The original test expected "master". Was this
some change in Git? I cannot find anything about this in Google, but
that's a small wonder as including "HEAD" in the query brings in a lot
of useless clutter.
This bug report was last modified 9 years and 311 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.