From: Andreas Schwab <schwab@linux-m68k.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 21457@debbugs.gnu.org
Subject: bug#21457: 25.0.50; vc-test-git03-working-revision test fails
Date: Sat, 12 Sep 2015 11:42:59 +0200 [thread overview]
Message-ID: <m2pp1o7z30.fsf@linux-m68k.org> (raw)
In-Reply-To: <83mvws2eov.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 12 Sep 2015 12:02:24 +0300")
Eli Zaretskii <eliz@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?
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
next prev parent reply other threads:[~2015-09-12 9:42 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-11 7:51 bug#21457: 25.0.50; vc-test-git03-working-revision test fails Eli Zaretskii
2015-09-11 20:30 ` Glenn Morris
2015-09-11 20:34 ` Glenn Morris
2015-09-12 9:02 ` Eli Zaretskii
2015-09-12 9:42 ` Andreas Schwab [this message]
2015-09-12 15:03 ` Eli Zaretskii
2015-09-12 15:36 ` Eli Zaretskii
2015-09-12 15:52 ` Eli Zaretskii
2015-09-12 16:54 ` Andreas Schwab
2015-09-12 17:10 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2pp1o7z30.fsf@linux-m68k.org \
--to=schwab@linux-m68k.org \
--cc=21457@debbugs.gnu.org \
--cc=eliz@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.