From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs,gmane.emacs.pretest.bugs Subject: bug#4933: 23.1.50; RCS buffer: save-buffer moves point to beginning of buffer Date: Mon, 16 Nov 2009 09:41:17 -0500 Message-ID: References: Reply-To: Stefan Monnier , 4933@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1258402115 22738 80.91.229.12 (16 Nov 2009 20:08:35 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 16 Nov 2009 20:08:35 +0000 (UTC) Cc: emacs-pretest-bug@gnu.org, 4933@emacsbugs.donarmstrong.com To: Carsten Bormann Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Nov 16 21:08:14 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1NA7rw-0000lE-JE for geb-bug-gnu-emacs@m.gmane.org; Mon, 16 Nov 2009 21:08:12 +0100 Original-Received: from localhost ([127.0.0.1]:39135 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NA7rw-0001Jo-3s for geb-bug-gnu-emacs@m.gmane.org; Mon, 16 Nov 2009 15:08:12 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NA7rI-0000d1-Du for bug-gnu-emacs@gnu.org; Mon, 16 Nov 2009 15:07:32 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NA7rE-0000X8-3x for bug-gnu-emacs@gnu.org; Mon, 16 Nov 2009 15:07:31 -0500 Original-Received: from [199.232.76.173] (port=55898 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NA7rC-0000Wf-LZ for bug-gnu-emacs@gnu.org; Mon, 16 Nov 2009 15:07:26 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:38645) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NA7rB-0006wj-Gh for bug-gnu-emacs@gnu.org; Mon, 16 Nov 2009 15:07:26 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nAGK7KKV001269; Mon, 16 Nov 2009 12:07:23 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id nAGJoPUG031230; Mon, 16 Nov 2009 11:50:25 -0800 Resent-Date: Mon, 16 Nov 2009 11:50:25 -0800 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Stefan Monnier Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Mon, 16 Nov 2009 19:50:24 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 4933 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 4933-submit@emacsbugs.donarmstrong.com id=B4933.125840012228285 (code B ref 4933); Mon, 16 Nov 2009 19:50:24 +0000 Original-Received: (at 4933) by emacsbugs.donarmstrong.com; 16 Nov 2009 19:35:22 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from ironport2-out.pppoe.ca (ironport2-out.teksavvy.com [206.248.154.183]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nAGEfNcx028780 for <4933@emacsbugs.donarmstrong.com>; Mon, 16 Nov 2009 06:41:24 -0800 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApsEAIfzAEtMCqHJ/2dsb2JhbACBTNRphDwEiT4 X-IronPort-AV: E=Sophos;i="4.44,751,1249272000"; d="scan'208";a="49469632" Original-Received: from 76-10-161-201.dsl.teksavvy.com (HELO pastel.home) ([76.10.161.201]) by ironport2-out.pppoe.ca with ESMTP; 16 Nov 2009 09:41:17 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id 34A91F1A31; Mon, 16 Nov 2009 09:41:17 -0500 (EST) In-Reply-To: (Carsten Bormann's message of "Mon, 16 Nov 2009 06:38:26 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Mon, 16 Nov 2009 15:07:31 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:32644 gmane.emacs.pretest.bugs:25193 Archived-At: > Start Emacs with -Q -q. > C-x C-f a file with an RCS version control file behind it. > perform some edit somewhere. > C-x C-s. > Bug: Point does not stay where it was, but jumps to the beginning of the file. > (Note that this does not seem to occur with, e.g., svn-controlled files.) Thank you for that precise bug report. I've just installed the patch below which should fix it, Stefan --- vc-rcs.el.~1.97.~ 2009-11-15 23:34:56.000000000 -0500 +++ vc-rcs.el 2009-11-16 09:38:57.000000000 -0500 @@ -1056,6 +1056,7 @@ ((not (get-file-buffer file)) nil) ((let (status version locking-user) (with-current-buffer (get-file-buffer file) + (save-excursion (goto-char (point-min)) (cond ;; search for $Id or $Header @@ -1112,7 +1113,7 @@ (setq status 'rev))) ;; else: nothing found ;; ------------------- - (t nil))) + (t nil)))) (if status (vc-file-setprop file 'vc-working-revision version)) (and (eq status 'rev-and-lock) (vc-file-setprop file 'vc-state