From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andreas Schwab Newsgroups: gmane.emacs.bugs Subject: bug#21457: 25.0.50; vc-test-git03-working-revision test fails Date: Sat, 12 Sep 2015 11:42:59 +0200 Message-ID: References: <83d1xp4cn0.fsf@gnu.org> <01lhcc3day.fsf@fencepost.gnu.org> <83mvws2eov.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1442051062 19316 80.91.229.3 (12 Sep 2015 09:44:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 12 Sep 2015 09:44:22 +0000 (UTC) Cc: 21457@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Sep 12 11:44:11 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZahLv-0004qm-6O for geb-bug-gnu-emacs@m.gmane.org; Sat, 12 Sep 2015 11:44:11 +0200 Original-Received: from localhost ([::1]:60079 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZahLt-0004AN-UQ for geb-bug-gnu-emacs@m.gmane.org; Sat, 12 Sep 2015 05:44:09 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43744) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZahLq-00048d-BS for bug-gnu-emacs@gnu.org; Sat, 12 Sep 2015 05:44:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZahLm-0003eu-B1 for bug-gnu-emacs@gnu.org; Sat, 12 Sep 2015 05:44:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:37204) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZahLm-0003eo-7Z for bug-gnu-emacs@gnu.org; Sat, 12 Sep 2015 05:44:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1ZahLl-0004pU-SD for bug-gnu-emacs@gnu.org; Sat, 12 Sep 2015 05:44:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Andreas Schwab Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 12 Sep 2015 09:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 21457 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 21457-submit@debbugs.gnu.org id=B21457.144205098618495 (code B ref 21457); Sat, 12 Sep 2015 09:44:01 +0000 Original-Received: (at 21457) by debbugs.gnu.org; 12 Sep 2015 09:43:06 +0000 Original-Received: from localhost ([127.0.0.1]:57647 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZahKr-0004oF-VP for submit@debbugs.gnu.org; Sat, 12 Sep 2015 05:43:06 -0400 Original-Received: from mail-out.m-online.net ([212.18.0.10]:58935) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZahKp-0004o4-F2 for 21457@debbugs.gnu.org; Sat, 12 Sep 2015 05:43:04 -0400 Original-Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 3nCpsd50XVz3hj2Y; Sat, 12 Sep 2015 11:43:01 +0200 (CEST) Original-Received: from localhost (dynscan1.mnet-online.de [192.168.6.68]) by mail.m-online.net (Postfix) with ESMTP id 3nCpsd3JVnzvkF3; Sat, 12 Sep 2015 11:43:01 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Original-Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.68]) (amavisd-new, port 10024) with ESMTP id mZBrinsXbNDn; Sat, 12 Sep 2015 11:43:00 +0200 (CEST) X-Auth-Info: zfGSXeXwDByNIE+/etEVxap6kffG/sC1l3X4kXXrlvxtvdj+lm2FAwq4hI5hr2i7 Original-Received: from linux.local (host-188-174-203-113.customer.m-online.net [188.174.203.113]) by mail.mnet-online.de (Postfix) with ESMTPA; Sat, 12 Sep 2015 11:43:00 +0200 (CEST) Original-Received: by linux.local (Postfix, from userid 501) id B249A1E52FE; Sat, 12 Sep 2015 11:42:59 +0200 (CEST) X-Yow: UH-OH!! We're out of AUTOMOBILE PARTS and RUBBER GOODS! In-Reply-To: <83mvws2eov.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 12 Sep 2015 12:02:24 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:106446 Archived-At: Eli Zaretskii 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."