From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: 23.1: reverting fails to update line ending mode line Reply-To: Benjamin Peterson , 4533@debbugs.gnu.org Resent-From: Benjamin Peterson Original-Sender: musiccomposition@gmail.com Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Wed, 23 Sep 2009 02:10:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: report 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by submit@emacsbugs.donarmstrong.com id=B.125367130417857 (code B ref -1); Wed, 23 Sep 2009 02:10:05 +0000 Received: (at submit) by emacsbugs.donarmstrong.com; 23 Sep 2009 02:01:44 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=0.1 required=4.0 tests=FOURLA autolearn=no version=3.2.5-bugs.debian.org_2005_01_02 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n8N21gS8017854 for ; Tue, 22 Sep 2009 19:01:43 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MqHAs-0007TV-66 for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:42 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MqHAn-0007RR-BT for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:41 -0400 Received: from [199.232.76.173] (port=56866 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MqHAn-0007RL-7x for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:37 -0400 Received: from mail-yw0-f194.google.com ([209.85.211.194]:52870) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MqHAm-00081S-L9 for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:36 -0400 Received: by ywh32 with SMTP id 32so394432ywh.14 for ; Tue, 22 Sep 2009 19:01:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:date :x-google-sender-auth:message-id:subject:from:to:content-type; bh=iS3MOAUsqS9oc4D5laIC+awm/vaISZnNMn2JPkUwNSU=; b=sXyo37Uj20TbtMl8hr1U44YQSAjZZm9zjHfeAZWR2/tHFNcGsQY0hmp92uCv35eMfC +X24M889fEC9L8Xs4atPNWMLB/L4bpGEyCVhoGyD5CpCnQPQiBUw1Y+Mx6Jx/OvAwpXl yqyQXlgwWNf8YeMaoNqjE35e+sUuOn1uukM8M= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; b=unlCYlsJmQqUfxyiXw92XDw/zFokLhIjilm4K292YwSLIo/Qf+EenIV5qh3m0+oo2k 4fSBFkANahuPFDTYYmCM20YHlMtMH4BQUUHmlwvxQR02O5dbxn4ISZXdNTqfIFwaHQJA RaRKKK82O5Whrpy41iCwPjzPVMPBhy2oaDW04= MIME-Version: 1.0 Sender: musiccomposition@gmail.com Received: by 10.90.174.7 with SMTP id w7mr994983age.11.1253671291410; Tue, 22 Sep 2009 19:01:31 -0700 (PDT) Date: Tue, 22 Sep 2009 21:01:31 -0500 X-Google-Sender-Auth: 3161eb516f81e56d Message-ID: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> From: Benjamin Peterson To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset=UTF-8 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) I had a buffer with a mode line like this: - U:(DOS) I ran dos2unix on the file, and did M-x revert-buffer. The DOS stayed in the mode line until I killed the buffer and revisited the buffer. In GNU Emacs 23.1.1 (x86_64-pc-linux-gnu) of 2009-09-07 on benjamin Windowing system distributor `The X.Org Foundation', version 11.0.10503000 configured using `configure '--prefix=/usr' '--build=x86_64-pc-linux-gnu' '--host=x86_64-pc-linux-gnu' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--datadir=/usr/share' '--sysconfdir=/etc' '--localstatedir=/var/lib' '--libdir=/usr/lib64' '--program-suffix=-emacs-23' '--infodir=/usr/share/info/emacs-23' '--with-sound' '--with-x' '--without-toolkit-scroll-bars' '--without-gif' '--with-jpeg' '--with-png' '--with-rsvg' '--with-tiff' '--with-xpm' '--with-xft' '--without-libotf' '--without-m17n-flt' '--with-x-toolkit=no' '--without-hesiod' '--without-kerberos' '--without-kerberos5' '--with-gpm' '--with-dbus' 'build_alias=x86_64-pc-linux-gnu' 'host_alias=x86_64-pc-linux-gnu' 'CFLAGS=-O2 -pipe' 'LDFLAGS=-Wl,-O1'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: nil value of $XMODIFIERS: nil locale-coding-system: nil default-enable-multibyte-characters: t Major mode: Python Minor modes in effect: show-paren-mode: t tooltip-mode: t tool-bar-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t global-auto-composition-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t Recent input: n i c o d e C-s C-s C-s C-s C-s C-s C-s C-x b M-v M-v M-v M-v C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-n C-n C-n C-n C-n C-n C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-p C-p C-p C-p C-p C-p C-p C-f C-f c l a s s SPC _ u n i c o d e ( s t r ) : p a s s C-x C-s C-v C-v C-v C-v C-v C-v C-v M-v M-v M-v C-x b _ C-x C-s M-v C-v C-n C-n C-n C-n C-n C-n C-n C-p # SPC S D p y . t e s t . s k i p ( " w i l l SPC r e w r i t e " ) C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n p y . t e s t . s k i p ( " w i l l SPC r e w r i t e " ) C-x C-s M-x r e v e r t - u f b u f y M-v M-v M-v f r C-x k C-x C-f t e s t - s e r _ s e r C-v C-v C-v M-v M-v M-x r e p o r t - e m Recent messages: Local value of py-indent-offset set to 4 Using the CPython shell test_serializer.py changed on disk; really edit the buffer? (y, n, r or C-h) Fontifying test_serializer.py... (regexps............) Local value of py-indent-offset set to 4 Using the CPython shell byte-code: File reverted: /home/benjamin/dev/repos/pylib/test_serializer.py Fontifying test_serializer.py... (regexps............) Local value of py-indent-offset set to 4 Using the CPython shell call-interactively: End of buffer From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: 23.1: reverting fails to update line ending mode line Reply-To: Glenn Morris , 4533@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Sat, 03 Oct 2009 00:25:06 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 4533-submit@emacsbugs.donarmstrong.com id=B4533.125452901229064 (code B ref 4533); Sat, 03 Oct 2009 00:25:06 +0000 Received: (at 4533) by emacsbugs.donarmstrong.com; 3 Oct 2009 00:16:52 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-7.5 required=4.0 tests=AWL,HAS_BUG_NUMBER, X_DEBBUGS_NO_ACK autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n930GoBb029061 for <4533@emacsbugs.donarmstrong.com>; Fri, 2 Oct 2009 17:16:52 -0700 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1MtsIs-0003SX-AY; Fri, 02 Oct 2009 20:16:50 -0400 From: Glenn Morris To: Benjamin Peterson Cc: 4533@debbugs.gnu.org References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> X-Spook: INSCOM Lon Horiuchi USCOI insurgency asset BLU-114/B X-Ran: R)CcTsqEsrPn_.XF"]h2yZ2^{]fNtnOYbtXi.@DEPmQ]wuawfpur}C3clyme%/,+s3Vm:w X-Hue: magenta X-Attribution: GM Date: Fri, 02 Oct 2009 20:16:50 -0400 In-Reply-To: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> (Benjamin Peterson's message of "Tue, 22 Sep 2009 21:01:31 -0500") Message-ID: <288wftcowd.fsf@fencepost.gnu.org> User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Benjamin Peterson wrote: > I had a buffer with a mode line like this: > > - U:(DOS) > > I ran dos2unix on the file, and did M-x revert-buffer. > > The DOS stayed in the mode line until I killed the buffer and > revisited the buffer. I have not been able to reproduce this. From rgm@gnu.org Fri Oct 2 17:15:07 2009 Received: (at control) by emacsbugs.donarmstrong.com; 3 Oct 2009 00:15:07 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-5.5 required=4.0 tests=AWL,ONEWORD,VALID_BTS_CONTROL, X_DEBBUGS_NO_ACK autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n930F5Nc028519 for ; Fri, 2 Oct 2009 17:15:06 -0700 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1MtsHB-0002df-2y; Fri, 02 Oct 2009 20:15:05 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <19142.38793.26660.496725@fencepost.gnu.org> Date: Fri, 2 Oct 2009 20:15:05 -0400 From: Glenn Morris To: control Subject: control X-Attribution: GM X-Mailer: VM (www.wonderworks.com/vm), GNU Emacs (www.gnu.org/software/emacs) X-Hue: yellow X-Ran: `1HVlPAe]oX58p&Mww>"vcHF148BX1RE=klf?{tlYoKADa1BE*zv, 4533@debbugs.gnu.org Resent-From: Jack Tanner Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Sun, 01 Nov 2009 17:15:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: unreproducible moreinfo Received: via spool by 4533-submit@emacsbugs.donarmstrong.com id=B4533.12570952636545 (code B ref 4533); Sun, 01 Nov 2009 17:15:04 +0000 Received: (at 4533) by emacsbugs.donarmstrong.com; 1 Nov 2009 17:07:43 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: * X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=1.1 required=4.0 tests=FOURLA,MULTALT autolearn=no version=3.2.5-bugs.debian.org_2005_01_02 Received: from blu0-omc2-s1.blu0.hotmail.com (blu0-omc2-s1.blu0.hotmail.com [65.55.111.76]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA1H7fc2006509 for <4533@emacsbugs.donarmstrong.com>; Sun, 1 Nov 2009 09:07:42 -0800 Received: from BLU129-W14 ([65.55.111.71]) by blu0-omc2-s1.blu0.hotmail.com with Microsoft SMTPSVC(6.0.3790.3959); Sun, 1 Nov 2009 09:07:36 -0800 Message-ID: Content-Type: multipart/alternative; boundary="_c7da0dc3-10d1-45c0-9188-41943cdd92fe_" X-Originating-IP: [71.182.160.22] From: Jack Tanner To: <4533@debbugs.gnu.org> CC: Date: Sun, 1 Nov 2009 12:07:36 -0500 Importance: Normal MIME-Version: 1.0 X-OriginalArrivalTime: 01 Nov 2009 17:07:36.0375 (UTC) FILETIME=[CF4B7470:01CA5B15] --_c7da0dc3-10d1-45c0-9188-41943cdd92fe_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Emacs 23.1.1 i386-mingw-nt5.1.2600 (from ftp.gnu.org) on WinXP SP3. - Start emacs -Q . - C-x C-f ~/foo.txt=2C creating a new file. - Enter text:=20 Line 1 Line 2 - C-x C-s. - dos2unix ~/foo.txt - M-x revert-buffer Nothing changes in the mode line. Mousing over the \ in -1\--- shows "End-o= f-line style: DOS-style CRLF". - C-x k RET - C-x C-f ~/foo.txt Mode line shows --(Unix)---. =20 _________________________________________________________________ Bing brings you maps=2C menus=2C and reviews organized in one place. http://www.bing.com/search?q=3Drestaurants&form=3DMFESRP&publ=3DWLHMTAG&cre= a=3DTEXT_MFESRP_Local_MapsMenu_Resturants_1x1= --_c7da0dc3-10d1-45c0-9188-41943cdd92fe_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Emacs 23.1.1 i386-mingw-nt5.1.2600 (from ftp.gnu.org) on WinXP SP3.
- Start emacs -Q .
- C-x C-f ~/foo.txt=2C creating a new file.
-= Enter text:
Line 1
Line 2

- C-x C-s.
- dos2unix ~/foo.txt=
- M-x revert-buffer
Nothing changes in the mode line. Mousing over t= he \ in -1\--- shows "End-of-line style: DOS-style CRLF".
- C-x k RET- C-x C-f ~/foo.txt
Mode line shows --(Unix)---.
<= br />
Bing brings you maps=2C menus=2C and reviews organized in one pl= ace. Try it now. = --_c7da0dc3-10d1-45c0-9188-41943cdd92fe_-- From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: i can reproduce this Reply-To: Glenn Morris , 4533@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Mon, 02 Nov 2009 08:20:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: unreproducible moreinfo Received: via spool by 4533-submit@emacsbugs.donarmstrong.com id=B4533.125714948019608 (code B ref 4533); Mon, 02 Nov 2009 08:20:03 +0000 Received: (at 4533) by emacsbugs.donarmstrong.com; 2 Nov 2009 08:11:20 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-8.3 required=4.0 tests=AWL,HAS_BUG_NUMBER, VALID_BTS_CONTROL,X_DEBBUGS_NO_ACK autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA28BJdc019595; Mon, 2 Nov 2009 00:11:20 -0800 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1N4s0T-000432-3t; Mon, 02 Nov 2009 03:11:17 -0500 From: Glenn Morris To: Jack Tanner Cc: 4533@debbugs.gnu.org References: X-Spook: CDC FIPS140 AK-47 BCCI Jyllandsposten cypherpunk X-Ran: 3$_IpzVjR>Ob>5IP;JwlA, (Jack Tanner's message of "Sun, 1 Nov 2009 12:07:36 -0500") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii tags 4533 = stop Jack Tanner wrote: > - Start emacs -Q . > - C-x C-f ~/foo.txt, creating a new file. > - Enter text: > Line 1 > Line 2 > > - C-x C-s. > - dos2unix ~/foo.txt > - M-x revert-buffer Thanks for the recipe. Saving the file was the missing step. The issue seems to be that saving a file causes basic-save-buffer-1 to set buffer-file-coding-system-explicit. Eg for me on GNU/Linux, it is set to (iso-latin-1-unix). revert-buffer uses this to set coding-system-for-read before it inserts the file contents. So the change in line ending is ignored. If I manually set buffer-file-coding-system-explicit to nil before reverting the buffer, the change in line ending is noticed. I don't know what the right fix is though. From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: reverting fails to update line ending mode line Reply-To: Glenn Morris , 4533@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Mon, 02 Nov 2009 09:05:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 4533-submit@emacsbugs.donarmstrong.com id=B4533.125715223625600 (code B ref 4533); Mon, 02 Nov 2009 09:05:04 +0000 Received: (at 4533) by emacsbugs.donarmstrong.com; 2 Nov 2009 08:57:16 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-7.3 required=4.0 tests=AWL,HAS_BUG_NUMBER, X_DEBBUGS_NO_ACK autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA28vF2g025597 for <4533@emacsbugs.donarmstrong.com>; Mon, 2 Nov 2009 00:57:16 -0800 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1N4siw-0006vd-GV; Mon, 02 Nov 2009 03:57:14 -0500 From: Glenn Morris To: 4533@debbugs.gnu.org References: X-Spook: warfare fraud ISEC virus Zachawi crypto anarchy Arnett X-Ran: iua2"KU!nr[8&tq1GUS{e}`kusg1Nt/|-];7#<43f[4=r$8XS&pnQU4noJ7ey.iW{,y`&1 X-Hue: red X-Attribution: GM Date: Mon, 02 Nov 2009 03:57:14 -0500 In-Reply-To: (Glenn Morris's message of "Mon, 02 Nov 2009 03:11:16 -0500") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii But http://debbugs.gnu.org/cgi/bugreport.cgi?bug=1039#42 seems to say this is a feature? But, the problem is the case that you load "hello" by explicitly specifying dos coding system, or you once save the file by dos coding sytem before reverting. In this case, Emacs respects your specification, and thus revert-buffer loads the file as dos coding system, which results in seeing many CR charaters in the above case. We think this behaviour is not a bug but a feature. From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: reverting fails to update line ending mode line Reply-To: Glenn Morris , 4533@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Thu, 05 Nov 2009 03:35:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 4533-submit@emacsbugs.donarmstrong.com id=B4533.125739172210597 (code B ref 4533); Thu, 05 Nov 2009 03:35:04 +0000 Received: (at 4533) by emacsbugs.donarmstrong.com; 5 Nov 2009 03:28:42 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-7.3 required=4.0 tests=AWL,HAS_BUG_NUMBER, X_DEBBUGS_NO_ACK autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA53SeUu010594 for <4533@emacsbugs.donarmstrong.com>; Wed, 4 Nov 2009 19:28:42 -0800 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1N5t1b-0004T0-UE; Wed, 04 Nov 2009 22:28:39 -0500 From: Glenn Morris To: Kenichi Handa References: cc: 4533@debbugs.gnu.org X-Spook: Semtex global Crypto AG United Nations Dick Cheney Bosnia X-Ran: ovl^%aQ.r|=iV)9$~V+}NQ`w(`1;.a_\pp5h{KK`/ X-Hue: black X-Attribution: GM Date: Wed, 04 Nov 2009 22:28:39 -0500 Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Hi, Could you comment on this http://debbugs.gnu.org/cgi/bugreport.cgi?bug=4533#15 (it seems related to your final comment in bug#1039) The behaviour in this case seems odd to me, given that the coding system is never explicitly specified. From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: 23.1: reverting fails to update line ending mode line Reply-To: Kenichi Handa , 4533@debbugs.gnu.org Resent-From: Kenichi Handa Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Thu, 05 Nov 2009 04:25:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by submit@emacsbugs.donarmstrong.com id=B.125739463515092 (code B ref -1); Thu, 05 Nov 2009 04:25:05 +0000 Received: (at submit) by emacsbugs.donarmstrong.com; 5 Nov 2009 04:17:15 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-2.5 required=4.0 tests=AWL,HAS_BUG_NUMBER, IMPRONONCABLE_2 autolearn=unavailable version=3.2.5-bugs.debian.org_2005_01_02 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA54HEKO015089 for ; Wed, 4 Nov 2009 20:17:15 -0800 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1N5tmc-0004j7-0Y for bug-gnu-emacs@gnu.org; Wed, 04 Nov 2009 23:17:14 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1N5tmV-0004he-QS for bug-gnu-emacs@gnu.org; Wed, 04 Nov 2009 23:17:12 -0500 Received: from [199.232.76.173] (port=54853 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N5tmV-0004hX-Mx for bug-gnu-emacs@gnu.org; Wed, 04 Nov 2009 23:17:07 -0500 Received: from mx1.aist.go.jp ([150.29.246.133]:59769) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1N5tmV-0007P9-4G for bug-gnu-emacs@gnu.org; Wed, 04 Nov 2009 23:17:07 -0500 Received: from rqsmtp2.aist.go.jp (rqsmtp2.aist.go.jp [150.29.254.123]) by mx1.aist.go.jp with ESMTP id nA54H1ja012999; Thu, 5 Nov 2009 13:17:01 +0900 (JST) env-from (handa@m17n.org) Received: from smtp4.aist.go.jp by rqsmtp2.aist.go.jp with ESMTP id nA54H1mY021377; Thu, 5 Nov 2009 13:17:01 +0900 (JST) env-from (handa@m17n.org) Received: by smtp4.aist.go.jp with ESMTP id nA54H0cc011347; Thu, 5 Nov 2009 13:17:00 +0900 (JST) env-from (handa@m17n.org) Received: from handa by etlken with local (Exim 4.69) (envelope-from ) id 1N5tmO-00012G-E7; Thu, 05 Nov 2009 13:17:00 +0900 From: Kenichi Handa To: Benjamin Peterson , 4533@debbugs.gnu.org Cc: bug-gnu-emacs@gnu.org In-Reply-To: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> (message from Benjamin Peterson on Tue, 22 Sep 2009 21:01:31 -0500) References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> Date: Thu, 05 Nov 2009 13:17:00 +0900 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-detected-operating-system: by monty-python.gnu.org: Solaris 9 In article <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com>, Benjamin Peterson writes: > I had a buffer with a mode line like this: > - U:(DOS) > I ran dos2unix on the file, and did M-x revert-buffer. > The DOS stayed in the mode line until I killed the buffer and > revisited the buffer. I found that insert-file-contents forgets to update buffer-file-coding-system in case of replace. I've just installed a fix. --- Kenichi Handa handa@m17n.org From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: reverting fails to update line ending mode line Reply-To: Kenichi Handa , 4533@debbugs.gnu.org Resent-From: Kenichi Handa Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Thu, 05 Nov 2009 04:25:10 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 4533-submit@emacsbugs.donarmstrong.com id=B4533.125739473315106 (code B ref 4533); Thu, 05 Nov 2009 04:25:10 +0000 Received: (at 4533) by emacsbugs.donarmstrong.com; 5 Nov 2009 04:18:53 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-3.0 required=4.0 tests=AWL,HAS_BUG_NUMBER, SPF_HELO_PASS autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from mx1.aist.go.jp (mx1.aist.go.jp [150.29.246.133]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA54IpBX015103 for <4533@emacsbugs.donarmstrong.com>; Wed, 4 Nov 2009 20:18:52 -0800 Received: from rqsmtp2.aist.go.jp (rqsmtp2.aist.go.jp [150.29.254.123]) by mx1.aist.go.jp with ESMTP id nA54Ioao013807; Thu, 5 Nov 2009 13:18:50 +0900 (JST) env-from (handa@m17n.org) Received: from smtp4.aist.go.jp by rqsmtp2.aist.go.jp with ESMTP id nA54IoDg021636; Thu, 5 Nov 2009 13:18:50 +0900 (JST) env-from (handa@m17n.org) Received: by smtp4.aist.go.jp with ESMTP id nA54InXD012166; Thu, 5 Nov 2009 13:18:49 +0900 (JST) env-from (handa@m17n.org) Received: from handa by etlken with local (Exim 4.69) (envelope-from ) id 1N5to9-00015l-PA; Thu, 05 Nov 2009 13:18:49 +0900 From: Kenichi Handa To: Glenn Morris Cc: 4533@debbugs.gnu.org In-Reply-To: (message from Glenn Morris on Wed, 04 Nov 2009 22:28:39 -0500) References: Date: Thu, 05 Nov 2009 13:18:49 +0900 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii In article , Glenn Morris writes: > Could you comment on this > http://debbugs.gnu.org/cgi/bugreport.cgi?bug=4533#15 I've just installed a fix, and replied to the above message. > (it seems related to your final comment in bug#1039) I don't think so. As I wrote in the mail, it's a simple bug in insert-file-contents. --- Kenichi Handa handa@m17n.org From unknown Mon Jun 23 23:51:29 2025 X-Loop: owner@emacsbugs.donarmstrong.com Subject: bug#4533: reverting fails to update line ending mode line Reply-To: Glenn Morris , 4533@debbugs.gnu.org Resent-From: Glenn Morris Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Thu, 05 Nov 2009 18:55:06 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-Emacs-PR-Message: followup 4533 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 4533-submit@emacsbugs.donarmstrong.com id=B4533.125744687231564 (code B ref 4533); Thu, 05 Nov 2009 18:55:06 +0000 Received: (at 4533) by emacsbugs.donarmstrong.com; 5 Nov 2009 18:47:52 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-7.3 required=4.0 tests=AWL,HAS_BUG_NUMBER, X_DEBBUGS_NO_ACK autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA5IlpNh031561 for <4533@emacsbugs.donarmstrong.com>; Thu, 5 Nov 2009 10:47:52 -0800 Received: from rgm by fencepost.gnu.org with local (Exim 4.67) (envelope-from ) id 1N67N7-0002EF-Qo; Thu, 05 Nov 2009 13:47:49 -0500 From: Glenn Morris To: Kenichi Handa Cc: 4533@debbugs.gnu.org References: X-Spook: supercomputer Albanian gamma Cohiba ammunition Mena X-Ran: 45AxeSy)frSG6f\-vezs0hp%:D#CxGPhwntB!$"3 X-Hue: magenta X-Attribution: GM Date: Thu, 05 Nov 2009 13:47:49 -0500 In-Reply-To: (Kenichi Handa's message of "Thu, 05 Nov 2009 13:18:49 +0900") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Kenichi Handa wrote: >> http://debbugs.gnu.org/cgi/bugreport.cgi?bug=4533#15 > > I've just installed a fix, and replied to the above message. Thanks, but it makes no difference for me on GNU/Linux. I use the same recipe as in the above message, but with "unix2dos" instead of "dos2unix". I just get "^M" appearing at the ends of lines on reverting. From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> In-Reply-To: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> Resent-From: Chong Yidong Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 13 Nov 2010 22:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Kenichi Handa Cc: 4533@debbugs.gnu.org Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.128968695324474 (code B ref 4533); Sat, 13 Nov 2010 22:23:02 +0000 Received: (at 4533) by debbugs.gnu.org; 13 Nov 2010 22:22:33 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHOUT-0006Mh-Fd for submit@debbugs.gnu.org; Sat, 13 Nov 2010 17:22:33 -0500 Received: from pantheon-po16.its.yale.edu ([130.132.50.72]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHOUR-0006Mc-3y for 4533@debbugs.gnu.org; Sat, 13 Nov 2010 17:22:31 -0500 Received: from furball (c-71-192-165-84.hsd1.ct.comcast.net [71.192.165.84]) (authenticated bits=0) by pantheon-po16.its.yale.edu (8.12.11.20060308/8.12.11) with ESMTP id oADMRM2r032453 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sat, 13 Nov 2010 17:27:23 -0500 Received: by furball (Postfix, from userid 1000) id 485B4160750; Sat, 13 Nov 2010 17:27:18 -0500 (EST) From: Chong Yidong Date: Sat, 13 Nov 2010 17:27:18 -0500 Message-ID: <87mxpcc115.fsf@stupidchicken.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-YaleITSMailFilter: Version 1.2c (attachment(s) not renamed) X-Spam-Score: -2.9 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.9 (--) > - Start emacs -Q . > - C-x C-f ~/foo.txt, creating a new file. > - Enter text: > Line 1 > Line 2 > > - C-x C-s. > - dos2unix ~/foo.txt > - M-x revert-buffer > - C-x k RET > - C-x C-f ~/foo.txt > Mode line shows --(Unix)--- The problem is that `C-x C-s' sets buffer-file-coding-system-explicit. This causes revert-buffer to set coding-system-for-read to that value (which is now incorrect) when inserting the file contents. This is why the revert goes correctly if you omit the `C-x C-s' step. I think the use of buffer-file-coding-system-explicit in revert-buffer is bogus, and should be removed---see below. What do you think? *** lisp/files.el 2010-11-11 22:19:01 +0000 --- lisp/files.el 2010-11-13 22:22:01 +0000 *************** *** 4906,4916 **** (let ((coding-system-for-read ;; Auto-saved file should be read by Emacs' ;; internal coding. ! (if auto-save-p 'auto-save-coding ! (or coding-system-for-read ! (and ! buffer-file-coding-system-explicit ! (car buffer-file-coding-system-explicit)))))) (if (and (not enable-multibyte-characters) coding-system-for-read (not (memq (coding-system-base --- 4906,4914 ---- (let ((coding-system-for-read ;; Auto-saved file should be read by Emacs' ;; internal coding. ! (if auto-save-p ! 'auto-save-coding ! coding-system-for-read))) (if (and (not enable-multibyte-characters) coding-system-for-read (not (memq (coding-system-base From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 14 Nov 2010 09:47:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Chong Yidong Cc: 4533@debbugs.gnu.org, handa@m17n.org Reply-To: Eli Zaretskii Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.128972798512199 (code B ref 4533); Sun, 14 Nov 2010 09:47:01 +0000 Received: (at 4533) by debbugs.gnu.org; 14 Nov 2010 09:46:25 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHZAG-0003Ai-Ke for submit@debbugs.gnu.org; Sun, 14 Nov 2010 04:46:24 -0500 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHZAE-0003Ad-22 for 4533@debbugs.gnu.org; Sun, 14 Nov 2010 04:46:22 -0500 Received: from eliz by fencepost.gnu.org with local (Exim 4.69) (envelope-from ) id 1PHZEv-0005Tf-LV; Sun, 14 Nov 2010 04:51:13 -0500 From: Eli Zaretskii In-reply-to: <87mxpcc115.fsf@stupidchicken.com> (message from Chong Yidong on Sat, 13 Nov 2010 17:27:18 -0500) References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> Message-Id: Date: Sun, 14 Nov 2010 04:51:13 -0500 X-Spam-Score: -6.5 (------) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.5 (------) > From: Chong Yidong > Date: Sat, 13 Nov 2010 17:27:18 -0500 > Cc: 4533@debbugs.gnu.org > > > - Start emacs -Q . > > - C-x C-f ~/foo.txt, creating a new file. > > - Enter text: > > Line 1 > > Line 2 > > > > - C-x C-s. > > - dos2unix ~/foo.txt > > - M-x revert-buffer > > - C-x k RET > > - C-x C-f ~/foo.txt > > Mode line shows --(Unix)--- > > The problem is that `C-x C-s' sets buffer-file-coding-system-explicit. > This causes revert-buffer to set coding-system-for-read to that value > (which is now incorrect) when inserting the file contents. This is why > the revert goes correctly if you omit the `C-x C-s' step. Why is this a real problem? I can handle this situation with C-x RET c undecided RET M-x revert-buffer RET (Perhaps "C-x RET r" should be fixed to do the same, when given `undecided' as the encoding.) > I think the use of buffer-file-coding-system-explicit in revert-buffer > is bogus, and should be removed---see below. What do you think? I'm not sure it's bogus. Why do you think so? Perhaps Handa-san remembers why this variable was introduced in the first place. I'm sure it was to solve some real-life problems. From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Chong Yidong Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 14 Nov 2010 17:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Eli Zaretskii Cc: 4533@debbugs.gnu.org, handa@m17n.org Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.128975567426676 (code B ref 4533); Sun, 14 Nov 2010 17:28:02 +0000 Received: (at 4533) by debbugs.gnu.org; 14 Nov 2010 17:27:54 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHgMs-0006wD-4C for submit@debbugs.gnu.org; Sun, 14 Nov 2010 12:27:54 -0500 Received: from pantheon-po26.its.yale.edu ([130.132.50.121]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHgMq-0006w7-4X for 4533@debbugs.gnu.org; Sun, 14 Nov 2010 12:27:52 -0500 Received: from furball (dhcp128036226184.central.yale.edu [128.36.226.184]) (authenticated bits=0) by pantheon-po26.its.yale.edu (8.12.11.20060308/8.12.11) with ESMTP id oAEHWkWW014733 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sun, 14 Nov 2010 12:32:46 -0500 Received: by furball (Postfix, from userid 1000) id D227A16055F; Sun, 14 Nov 2010 12:32:45 -0500 (EST) From: Chong Yidong References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> Date: Sun, 14 Nov 2010 12:32:45 -0500 In-Reply-To: (Eli Zaretskii's message of "Sun, 14 Nov 2010 04:51:13 -0500") Message-ID: <87oc9r7qv6.fsf@stupidchicken.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-YaleITSMailFilter: Version 1.2c (attachment(s) not renamed) X-Spam-Score: -2.7 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.7 (--) Eli Zaretskii writes: > Why is this a real problem? I can handle this situation with > > C-x RET c undecided RET M-x revert-buffer RET Sure; you can also kill the buffer and visit the file again with C-x C-f, making the revert-buffer command redundant. That's not really the point. The fact that revert-buffer correctly changes the coding system if you do one thing (i.e. visit the file but haven't yet saved), and does another thing if you do another (i.e. save some changes first) indicates that this is a real bug. From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Dani Moncayo Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 14 Nov 2010 20:19:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Chong Yidong Cc: Eli Zaretskii , 4533@debbugs.gnu.org Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.12897659001872 (code B ref 4533); Sun, 14 Nov 2010 20:19:01 +0000 Received: (at 4533) by debbugs.gnu.org; 14 Nov 2010 20:18:20 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHj1n-0000U9-RY for submit@debbugs.gnu.org; Sun, 14 Nov 2010 15:18:20 -0500 Received: from mail-yx0-f172.google.com ([209.85.213.172]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHj1l-0000U4-K0 for 4533@debbugs.gnu.org; Sun, 14 Nov 2010 15:18:18 -0500 Received: by yxs7 with SMTP id 7so539602yxs.3 for <4533@debbugs.gnu.org>; Sun, 14 Nov 2010 12:23:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=ae7n9tSmzzLZbvomFIsRG5tvA9jjnN/thcQ3HMsJ6tw=; b=Y+sBx7hjDr5Wmk3J07VmtnAZ4zrMqoW2S5RobQgCbGEpN8x1rgNkZ9E8UDSr3SEx6y raNWbqYYom1FFOqIqMebPXsyFtnRxU/3yl2RRsKhn3MPtw7NKRqH2CTBLyspu9+cLsYw g+R23nEDnMohrpN1bZlo9BCQWyXAQCsaKk5hY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=SmKCAAH5FV0lOGSkPKzEbNIApuB3ScAK1EX65823/aPEeyG47UTRBA2Knu+ptR0t+P oCNfoQv5V3Imq16fkbiqMudeCjJEfEZRU/RSdwvmfJwYL4//+yYDsRUvR19ahNDfX+mQ +deg+lFMGy/1dKWIhV8qMjApXwAbWWjkb3Ets= MIME-Version: 1.0 Received: by 10.90.7.15 with SMTP id 15mr6764755agg.13.1289766192074; Sun, 14 Nov 2010 12:23:12 -0800 (PST) Received: by 10.90.227.16 with HTTP; Sun, 14 Nov 2010 12:23:12 -0800 (PST) In-Reply-To: <87oc9r7qv6.fsf@stupidchicken.com> References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> <87oc9r7qv6.fsf@stupidchicken.com> Date: Sun, 14 Nov 2010 21:23:12 +0100 Message-ID: From: Dani Moncayo Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -3.1 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.1 (---) On Sun, Nov 14, 2010 at 6:32 PM, Chong Yidong wrote= : > Eli Zaretskii writes: > >> Why is this a real problem? =A0I can handle this situation with >> >> =A0 =A0 C-x RET c undecided RET M-x revert-buffer RET > > Sure; you can also kill the buffer and visit the file again with > C-x C-f, making the revert-buffer command redundant. =A0That's not really > the point. > > The fact that revert-buffer correctly changes the coding system if you > do one thing (i.e. visit the file but haven't yet saved), and does > another thing if you do another (i.e. save some changes first) indicates > that this is a real bug. > Isn't this bug a duplicated from bug #7383? (Actually, bug #7383 is about two different problems) From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 14 Nov 2010 20:42:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Dani Moncayo Cc: cyd@stupidchicken.com, 4533@debbugs.gnu.org Reply-To: Eli Zaretskii Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.12897672832457 (code B ref 4533); Sun, 14 Nov 2010 20:42:01 +0000 Received: (at 4533) by debbugs.gnu.org; 14 Nov 2010 20:41:23 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHjO7-0000da-Gn for submit@debbugs.gnu.org; Sun, 14 Nov 2010 15:41:23 -0500 Received: from mtaout20.012.net.il ([80.179.55.166]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHjO4-0000dT-Fc for 4533@debbugs.gnu.org; Sun, 14 Nov 2010 15:41:21 -0500 Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0LBW00C006X23R00@a-mtaout20.012.net.il> for 4533@debbugs.gnu.org; Sun, 14 Nov 2010 22:45:53 +0200 (IST) Received: from HOME-C4E4A596F7 ([77.126.249.126]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0LBW00BJS70G18D0@a-mtaout20.012.net.il>; Sun, 14 Nov 2010 22:45:53 +0200 (IST) Date: Sun, 14 Nov 2010 22:46:01 +0200 From: Eli Zaretskii In-reply-to: X-012-Sender: halo1@inter.net.il Message-id: <83pqu7d46u.fsf@gnu.org> References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> <87oc9r7qv6.fsf@stupidchicken.com> X-Spam-Score: -2.1 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.1 (--) > Date: Sun, 14 Nov 2010 21:23:12 +0100 > From: Dani Moncayo > Cc: Eli Zaretskii , 4533@debbugs.gnu.org > > Isn't this bug a duplicated from bug #7383? (Actually, bug #7383 is > about two different problems) How can bug #4533 be a duplicate of #7383? Is someone able of predicting the future? If so, I'd like to consult him/her about my stocks. From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Dani Moncayo Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 14 Nov 2010 20:51:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Eli Zaretskii Cc: cyd@stupidchicken.com, 4533@debbugs.gnu.org Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.12897678412720 (code B ref 4533); Sun, 14 Nov 2010 20:51:03 +0000 Received: (at 4533) by debbugs.gnu.org; 14 Nov 2010 20:50:41 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHjX7-0000hp-EA for submit@debbugs.gnu.org; Sun, 14 Nov 2010 15:50:41 -0500 Received: from mail-gy0-f172.google.com ([209.85.160.172]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHjX6-0000hk-NU for 4533@debbugs.gnu.org; Sun, 14 Nov 2010 15:50:41 -0500 Received: by gyh20 with SMTP id 20so2456803gyh.3 for <4533@debbugs.gnu.org>; Sun, 14 Nov 2010 12:55:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=S7DD7rwTof0CjOa0MxQm456ioQ15N8gFl/2ZwJhH6wg=; b=xGxCCNBXIyp2D3x9ZxlNEG1JyArmUjPjyY2pnX8Pp1YKF+tEl5o5jcXPAE2Pl+ChgN l/zPhYG0maU2xGGW6EHJU2lCtHYhdxpVVNn0prsduqavuPGgFa2716w5bpb9Jap+9qT9 ncyeLWKQLYOh6f1AS7Jxo166bhasB9LhRQgrc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=wekqmAQKmgVlS6AlFTFpR0gdvuUOXKFtwS9wt/QMKV4FNpjFMDkac8+ASYghfopwtP TSpWZorJAu81XoCyxTkcOOBH+MO0Tw3Z9v8KKacbFxrujBnwmHbsOPsiJ41GSYmHmvim vfl9tnWJchPmxR0QxhWu5zPjJWIZMOcaxG/dQ= MIME-Version: 1.0 Received: by 10.91.42.23 with SMTP id u23mr6739608agj.67.1289768134386; Sun, 14 Nov 2010 12:55:34 -0800 (PST) Received: by 10.90.227.16 with HTTP; Sun, 14 Nov 2010 12:55:34 -0800 (PST) In-Reply-To: <83pqu7d46u.fsf@gnu.org> References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> <87oc9r7qv6.fsf@stupidchicken.com> <83pqu7d46u.fsf@gnu.org> Date: Sun, 14 Nov 2010 21:55:34 +0100 Message-ID: From: Dani Moncayo Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -3.1 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.1 (---) On Sun, Nov 14, 2010 at 9:46 PM, Eli Zaretskii wrote: >> Date: Sun, 14 Nov 2010 21:23:12 +0100 >> From: Dani Moncayo >> Cc: Eli Zaretskii , 4533@debbugs.gnu.org >> >> Isn't this bug a duplicated from bug #7383? (Actually, bug #7383 is >> about two different problems) > > How can bug #4533 be a duplicate of #7383? =A0Is someone able of > predicting the future? =A0If so, I'd like to consult him/her about my > stocks. > Yes, the numbering is strange. I noticed that. But check the shipment dates. Which bug was filed earlier? From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Dani Moncayo Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 14 Nov 2010 21:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Eli Zaretskii Cc: cyd@stupidchicken.com, 4533@debbugs.gnu.org Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.12897709704494 (code B ref 4533); Sun, 14 Nov 2010 21:43:02 +0000 Received: (at 4533) by debbugs.gnu.org; 14 Nov 2010 21:42:50 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHkLZ-0001AR-Qn for submit@debbugs.gnu.org; Sun, 14 Nov 2010 16:42:49 -0500 Received: from mail-yw0-f44.google.com ([209.85.213.44]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PHkLX-0001AK-Pb for 4533@debbugs.gnu.org; Sun, 14 Nov 2010 16:42:48 -0500 Received: by ywp6 with SMTP id 6so2834725ywp.3 for <4533@debbugs.gnu.org>; Sun, 14 Nov 2010 13:47:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=J2gIxYPWxdgiJO0C1oggslYABMQoTLht9DwZmIcD9iw=; b=KXvWIpHscSot1+mU2r/IuIWC21H3xdw78iJwt26GUeo3vMz7jKjpSc1OkjOucza81X 2T07yOmAbCMP8Il0o3ubPRQim6GI9JFMw3OApWMIZmv1QTqBTNhQWif3YWO42fLjWC/W 1xEFP5OFpzDysEr5UD7+obD65sSYEw5Eb3x0g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=KcVbBvknspZ38w/G7PXbKj45DdFXxBXYdvQV5//Q48zNsNlF4xQsnjU+wXFwdN2fcS h8xCFlrWfdg9nAk9zcoaM4nbuA1cCbK8TPsfJRucc2tlq5oIt9NMd3FRCZrkl7z4Q6y3 5yb+HMQEorS1YdxpPxUDp8YfMjgbsQFDYEBRY= MIME-Version: 1.0 Received: by 10.91.11.3 with SMTP id o3mr6793507agi.148.1289771262293; Sun, 14 Nov 2010 13:47:42 -0800 (PST) Received: by 10.90.227.16 with HTTP; Sun, 14 Nov 2010 13:47:42 -0800 (PST) In-Reply-To: References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> <87oc9r7qv6.fsf@stupidchicken.com> <83pqu7d46u.fsf@gnu.org> Date: Sun, 14 Nov 2010 22:47:42 +0100 Message-ID: From: Dani Moncayo Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -3.1 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.1 (---) On Sun, Nov 14, 2010 at 9:55 PM, Dani Moncayo wrote: > On Sun, Nov 14, 2010 at 9:46 PM, Eli Zaretskii wrote: >>> Date: Sun, 14 Nov 2010 21:23:12 +0100 >>> From: Dani Moncayo >>> Cc: Eli Zaretskii , 4533@debbugs.gnu.org >>> >>> Isn't this bug a duplicated from bug #7383? (Actually, bug #7383 is >>> about two different problems) >> >> How can bug #4533 be a duplicate of #7383? =A0Is someone able of >> predicting the future? =A0If so, I'd like to consult him/her about my >> stocks. >> > > Yes, the numbering is strange. I noticed that. But check the shipment > dates. Which bug was filed earlier? > Ooops, I'm sorry. I don't know how I searched the bugs archives. #4533 it a lot older than #7383. But both are related bugs. From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 15 Nov 2010 16:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Chong Yidong Cc: 4533@debbugs.gnu.org, Kenichi Handa Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.12898396063375 (code B ref 4533); Mon, 15 Nov 2010 16:47:02 +0000 Received: (at 4533) by debbugs.gnu.org; 15 Nov 2010 16:46:46 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PI2Cb-0000sO-O0 for submit@debbugs.gnu.org; Mon, 15 Nov 2010 11:46:45 -0500 Received: from ironport2-out.teksavvy.com ([206.248.154.183] helo=ironport2-out.pppoe.ca) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PI2CW-0000sI-Ut for 4533@debbugs.gnu.org; Mon, 15 Nov 2010 11:46:44 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0GACPz4ExFpY76/2dsb2JhbAChWn9yvl6FSgSEWo1f X-IronPort-AV: E=Sophos;i="4.59,200,1288584000"; d="scan'208";a="82594208" Received: from 69-165-142-250.dsl.teksavvy.com (HELO pastel.home) ([69.165.142.250]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 15 Nov 2010 11:51:36 -0500 Received: by pastel.home (Postfix, from userid 20848) id 8C816A8263; Mon, 15 Nov 2010 11:51:36 -0500 (EST) From: Stefan Monnier Message-ID: References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> Date: Mon, 15 Nov 2010 11:51:36 -0500 In-Reply-To: <87mxpcc115.fsf@stupidchicken.com> (Chong Yidong's message of "Sat, 13 Nov 2010 17:27:18 -0500") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.1 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.1 (--) > I think the use of buffer-file-coding-system-explicit in revert-buffer > is bogus, and should be removed---see below. What do you think? Its use is not bogus. It's so that when a file's coding-system is incorrectly auto-detected, the user can force the use of a correct coding-system and subsequent revert-buffers won't disregard it. So maybe the problem is that C-x C-s should not set buffer-file-coding-system-explicit (unless the C-x C-s prompted the user to choose a coding-system, I guess). Stefan From unknown Mon Jun 23 23:51:29 2025 X-Loop: help-debbugs@gnu.org Subject: bug#4533: 23.1: reverting fails to update line ending mode line Resent-From: Chong Yidong Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 15 Nov 2010 17:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4533 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: 4533@debbugs.gnu.org, Kenichi Handa Received: via spool by 4533-submit@debbugs.gnu.org id=B4533.12898417664288 (code B ref 4533); Mon, 15 Nov 2010 17:23:02 +0000 Received: (at 4533) by debbugs.gnu.org; 15 Nov 2010 17:22:46 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PI2lS-000177-4z for submit@debbugs.gnu.org; Mon, 15 Nov 2010 12:22:46 -0500 Received: from pantheon-po41.its.yale.edu ([130.132.50.98]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PI2lP-000171-Ap for 4533@debbugs.gnu.org; Mon, 15 Nov 2010 12:22:43 -0500 Received: from furball (dhcp128036014113.central.yale.edu [128.36.14.113]) (authenticated bits=0) by pantheon-po41.its.yale.edu (8.12.11.20060308/8.12.11) with ESMTP id oAFHReBq009580 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Mon, 15 Nov 2010 12:27:40 -0500 Received: by furball (Postfix, from userid 1000) id 3F8FD1605A6; Mon, 15 Nov 2010 12:27:39 -0500 (EST) From: Chong Yidong References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> Date: Mon, 15 Nov 2010 12:27:39 -0500 In-Reply-To: (Stefan Monnier's message of "Mon, 15 Nov 2010 11:51:36 -0500") Message-ID: <87bp5qbipg.fsf@stupidchicken.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-YaleITSMailFilter: Version 1.2c (attachment(s) not renamed) X-Spam-Score: -2.7 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.7 (--) Stefan Monnier writes: >> I think the use of buffer-file-coding-system-explicit in revert-buffer >> is bogus, and should be removed---see below. What do you think? > > Its use is not bogus. It's so that when a file's coding-system is > incorrectly auto-detected, the user can force the use of a correct > coding-system and subsequent revert-buffers won't disregard it. > > So maybe the problem is that C-x C-s should not set > buffer-file-coding-system-explicit (unless the C-x C-s prompted the user > to choose a coding-system, I guess). I see. The comments in mule.el say that ;; This variable is set in these three cases: ;; (1) A file is read by a coding system specified explicitly. ;; after-insert-file-set-coding sets the car of this value to ;; coding-system-for-read, and sets the cdr to nil. ;; (2) A buffer is saved. ;; After writing, basic-save-buffer-1 sets the car of this value ;; to last-coding-system-used. ;; (3) set-buffer-file-coding-system is called. ;; The cdr of this value is set to the specified coding system. ;; This variable is used for decoding in revert-buffer and encoding in ;; select-safe-coding-system. Indeed, this seems to imply that (2) can be omitted, as you suggest, since "force selecting" a coding system should trigger (1) and (3). Is there any reason that (2) was originally included? From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 22 21:17:44 2012 Received: (at control) by debbugs.gnu.org; 23 Dec 2012 02:17:44 +0000 Received: from localhost ([127.0.0.1]:56034 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tmb8K-0002hJ-3i for submit@debbugs.gnu.org; Sat, 22 Dec 2012 21:17:44 -0500 Received: from fencepost.gnu.org ([208.118.235.10]:54124) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tmb8H-0002h5-8l; Sat, 22 Dec 2012 21:17:41 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1Tmb7u-000119-3y; Sat, 22 Dec 2012 21:17:18 -0500 From: Glenn Morris To: Reuben Thomas Subject: Re: bug#13256: 24.1; auto-revert does not re-check encoding References: <87wqw9r66q.fsf@sc3d.org> X-Spook: PLO Aladdin Project Monarch Ceridian $400 million in gold X-Ran: EH^~i6y6pk&J3~^l7U+o4PIs[N[3@.Q"0^./TQE8'b^R)}ZDX&Q)r$~:#gqayU_@{~YTae X-Hue: green X-Debbugs-No-Ack: yes X-Attribution: GM Date: Sat, 22 Dec 2012 21:17:18 -0500 In-Reply-To: <87wqw9r66q.fsf@sc3d.org> (Reuben Thomas's message of "Sat, 22 Dec 2012 23:57:33 +0000") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -2.7 (--) X-Debbugs-Envelope-To: control Cc: 13256@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.0 (----) merge 4533 13256 stop Reuben Thomas wrote: > I use auto-revert-mode. If I run e.g. dos2unix on a buffer I'm editing, > it is reverted, but Emacs does not notice that the line ending encoding > has changed. Hence, continuing to edit and re-saving will undo the > unix2dos command. http://debbugs.gnu.org/4533 From unknown Mon Jun 23 23:51:29 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.428 (Entity 5.428) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Benjamin Peterson Subject: bug#4533: closed (Re: bug#4533: 23.1: reverting fails to update line ending mode line) Message-ID: References: <87zjzc3lvk.fsf@gnu.org> <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> X-Gnu-PR-Message: they-closed 4533 X-Gnu-PR-Package: emacs Reply-To: 4533@debbugs.gnu.org Date: Sun, 10 Feb 2013 03:11:07 +0000 Content-Type: multipart/mixed; boundary="----------=_1360465867-2559-1" This is a multi-part message in MIME format... ------------=_1360465867-2559-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #4533: 23.1: reverting fails to update line ending mode line which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 4533@debbugs.gnu.org. --=20 4533: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D4533 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1360465867-2559-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 4533-done) by debbugs.gnu.org; 10 Feb 2013 03:10:31 +0000 Received: from localhost ([127.0.0.1]:47688 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U4NIv-0000e5-Kz for submit@debbugs.gnu.org; Sat, 09 Feb 2013 22:10:26 -0500 Received: from mail-pb0-f41.google.com ([209.85.160.41]:45094) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U4NIr-0000dv-Vl for 4533-done@debbugs.gnu.org; Sat, 09 Feb 2013 22:10:07 -0500 Received: by mail-pb0-f41.google.com with SMTP id um15so267033pbc.14 for <4533-done@debbugs.gnu.org>; Sat, 09 Feb 2013 19:09:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-type; bh=PxZNu2Akyd3KCa8on74xmf5W7i2kyMQEQZ5GtqJngyI=; b=PzD5T9G1Hf6MYi9PfortxgsaRi4aPVFkmnU1waWLHKKqt5H5d7jrJulSr3U1f7b1yA o0aa9t9NU7O0Udo8tIgUYJRRmsM4gdk88ZNnAwjZYyti89idLYptKCXOztBFMKDMAfJI K2dkWM7IG7eLacNmPCWL+QS4HIaAnjCLyY9h2sZ/KkDMCcXAlsYLk0sADK5gF+8/SOci i9H9h9L5ul8JcXKdiJkL6RHTgcMWa4c6s8GUOTMqgeyHZv2VrH2VRRI3D2Eulw6oTHUb Ce4iit/IijBl9oOwkPoxB22WKCtellPyEQIhNU+gtEoK3XJ+sFe0Z8cI/8ZewlLAveaB 1WmQ== X-Received: by 10.68.197.131 with SMTP id iu3mr7627608pbc.72.1360465793090; Sat, 09 Feb 2013 19:09:53 -0800 (PST) Received: from tsparkle (cm126.delta178.maxonline.com.sg. [59.189.178.126]) by mx.google.com with ESMTPS id xg1sm3190641pbc.26.2013.02.09.19.09.49 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sat, 09 Feb 2013 19:09:51 -0800 (PST) From: Chong Yidong To: Stefan Monnier Subject: Re: bug#4533: 23.1: reverting fails to update line ending mode line References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> <87bp5qbipg.fsf@stupidchicken.com> Date: Sun, 10 Feb 2013 11:09:51 +0800 In-Reply-To: <87bp5qbipg.fsf@stupidchicken.com> (Chong Yidong's message of "Mon, 15 Nov 2010 12:27:39 -0500") Message-ID: <87zjzc3lvk.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.93 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 4533-done Cc: Kenichi Handa , 4533-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) Chong Yidong writes: >> So maybe the problem is that C-x C-s should not set >> buffer-file-coding-system-explicit (unless the C-x C-s prompted the user >> to choose a coding-system, I guess). > > I see. The comments in mule.el say that > > ;; This variable is set in these three cases: > ;; (1) A file is read by a coding system specified explicitly. > ;; after-insert-file-set-coding sets the car of this value to > ;; coding-system-for-read, and sets the cdr to nil. > ;; (2) A buffer is saved. > ;; After writing, basic-save-buffer-1 sets the car of this value > ;; to last-coding-system-used. > ;; (3) set-buffer-file-coding-system is called. > ;; The cdr of this value is set to the specified coding system. > ;; This variable is used for decoding in revert-buffer and encoding in > ;; select-safe-coding-system. > > Indeed, this seems to imply that (2) can be omitted, as you suggest, > since "force selecting" a coding system should trigger (1) and (3). Is > there any reason that (2) was originally included? Since there's been no response, and my testing showed no ill effects to this change, I went ahead and committed it in the trunk. Let's see how it shakes out. ------------=_1360465867-2559-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by emacsbugs.donarmstrong.com; 23 Sep 2009 02:01:44 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02 (2008-06-10) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=0.1 required=4.0 tests=FOURLA autolearn=no version=3.2.5-bugs.debian.org_2005_01_02 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n8N21gS8017854 for ; Tue, 22 Sep 2009 19:01:43 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MqHAs-0007TV-66 for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:42 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MqHAn-0007RR-BT for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:41 -0400 Received: from [199.232.76.173] (port=56866 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MqHAn-0007RL-7x for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:37 -0400 Received: from mail-yw0-f194.google.com ([209.85.211.194]:52870) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MqHAm-00081S-L9 for bug-gnu-emacs@gnu.org; Tue, 22 Sep 2009 22:01:36 -0400 Received: by ywh32 with SMTP id 32so394432ywh.14 for ; Tue, 22 Sep 2009 19:01:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:date :x-google-sender-auth:message-id:subject:from:to:content-type; bh=iS3MOAUsqS9oc4D5laIC+awm/vaISZnNMn2JPkUwNSU=; b=sXyo37Uj20TbtMl8hr1U44YQSAjZZm9zjHfeAZWR2/tHFNcGsQY0hmp92uCv35eMfC +X24M889fEC9L8Xs4atPNWMLB/L4bpGEyCVhoGyD5CpCnQPQiBUw1Y+Mx6Jx/OvAwpXl yqyQXlgwWNf8YeMaoNqjE35e+sUuOn1uukM8M= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; b=unlCYlsJmQqUfxyiXw92XDw/zFokLhIjilm4K292YwSLIo/Qf+EenIV5qh3m0+oo2k 4fSBFkANahuPFDTYYmCM20YHlMtMH4BQUUHmlwvxQR02O5dbxn4ISZXdNTqfIFwaHQJA RaRKKK82O5Whrpy41iCwPjzPVMPBhy2oaDW04= MIME-Version: 1.0 Sender: musiccomposition@gmail.com Received: by 10.90.174.7 with SMTP id w7mr994983age.11.1253671291410; Tue, 22 Sep 2009 19:01:31 -0700 (PDT) Date: Tue, 22 Sep 2009 21:01:31 -0500 X-Google-Sender-Auth: 3161eb516f81e56d Message-ID: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> Subject: 23.1: reverting fails to update line ending mode line From: Benjamin Peterson To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset=UTF-8 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) I had a buffer with a mode line like this: - U:(DOS) I ran dos2unix on the file, and did M-x revert-buffer. The DOS stayed in the mode line until I killed the buffer and revisited the buffer. In GNU Emacs 23.1.1 (x86_64-pc-linux-gnu) of 2009-09-07 on benjamin Windowing system distributor `The X.Org Foundation', version 11.0.10503000 configured using `configure '--prefix=/usr' '--build=x86_64-pc-linux-gnu' '--host=x86_64-pc-linux-gnu' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--datadir=/usr/share' '--sysconfdir=/etc' '--localstatedir=/var/lib' '--libdir=/usr/lib64' '--program-suffix=-emacs-23' '--infodir=/usr/share/info/emacs-23' '--with-sound' '--with-x' '--without-toolkit-scroll-bars' '--without-gif' '--with-jpeg' '--with-png' '--with-rsvg' '--with-tiff' '--with-xpm' '--with-xft' '--without-libotf' '--without-m17n-flt' '--with-x-toolkit=no' '--without-hesiod' '--without-kerberos' '--without-kerberos5' '--with-gpm' '--with-dbus' 'build_alias=x86_64-pc-linux-gnu' 'host_alias=x86_64-pc-linux-gnu' 'CFLAGS=-O2 -pipe' 'LDFLAGS=-Wl,-O1'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: nil value of $XMODIFIERS: nil locale-coding-system: nil default-enable-multibyte-characters: t Major mode: Python Minor modes in effect: show-paren-mode: t tooltip-mode: t tool-bar-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t global-auto-composition-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t Recent input: n i c o d e C-s C-s C-s C-s C-s C-s C-s C-x b M-v M-v M-v M-v C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-n C-n C-n C-n C-n C-n C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-f C-p C-p C-p C-p C-p C-p C-p C-f C-f c l a s s SPC _ u n i c o d e ( s t r ) : p a s s C-x C-s C-v C-v C-v C-v C-v C-v C-v M-v M-v M-v C-x b _ C-x C-s M-v C-v C-n C-n C-n C-n C-n C-n C-n C-p # SPC S D p y . t e s t . s k i p ( " w i l l SPC r e w r i t e " ) C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n p y . t e s t . s k i p ( " w i l l SPC r e w r i t e " ) C-x C-s M-x r e v e r t - u f b u f y M-v M-v M-v f r C-x k C-x C-f t e s t - s e r _ s e r C-v C-v C-v M-v M-v M-x r e p o r t - e m Recent messages: Local value of py-indent-offset set to 4 Using the CPython shell test_serializer.py changed on disk; really edit the buffer? (y, n, r or C-h) Fontifying test_serializer.py... (regexps............) Local value of py-indent-offset set to 4 Using the CPython shell byte-code: File reverted: /home/benjamin/dev/repos/pylib/test_serializer.py Fontifying test_serializer.py... (regexps............) Local value of py-indent-offset set to 4 Using the CPython shell call-interactively: End of buffer ------------=_1360465867-2559-1-- From unknown Mon Jun 23 23:51:29 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.428 (Entity 5.428) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Reuben Thomas Subject: bug#13256: closed (Re: bug#4533: 23.1: reverting fails to update line ending mode line) Message-ID: References: <87zjzc3lvk.fsf@gnu.org> <87wqw9r66q.fsf@sc3d.org> X-Gnu-PR-Message: they-closed 13256 X-Gnu-PR-Package: emacs Reply-To: 13256@debbugs.gnu.org Date: Sun, 10 Feb 2013 03:11:09 +0000 Content-Type: multipart/mixed; boundary="----------=_1360465869-2559-3" This is a multi-part message in MIME format... ------------=_1360465869-2559-3 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #4533: 24.1; auto-revert does not re-check encoding which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 13256@debbugs.gnu.org. --=20 4533: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D4533 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1360465869-2559-3 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 4533-done) by debbugs.gnu.org; 10 Feb 2013 03:10:31 +0000 Received: from localhost ([127.0.0.1]:47688 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U4NIv-0000e5-Kz for submit@debbugs.gnu.org; Sat, 09 Feb 2013 22:10:26 -0500 Received: from mail-pb0-f41.google.com ([209.85.160.41]:45094) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U4NIr-0000dv-Vl for 4533-done@debbugs.gnu.org; Sat, 09 Feb 2013 22:10:07 -0500 Received: by mail-pb0-f41.google.com with SMTP id um15so267033pbc.14 for <4533-done@debbugs.gnu.org>; Sat, 09 Feb 2013 19:09:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-type; bh=PxZNu2Akyd3KCa8on74xmf5W7i2kyMQEQZ5GtqJngyI=; b=PzD5T9G1Hf6MYi9PfortxgsaRi4aPVFkmnU1waWLHKKqt5H5d7jrJulSr3U1f7b1yA o0aa9t9NU7O0Udo8tIgUYJRRmsM4gdk88ZNnAwjZYyti89idLYptKCXOztBFMKDMAfJI K2dkWM7IG7eLacNmPCWL+QS4HIaAnjCLyY9h2sZ/KkDMCcXAlsYLk0sADK5gF+8/SOci i9H9h9L5ul8JcXKdiJkL6RHTgcMWa4c6s8GUOTMqgeyHZv2VrH2VRRI3D2Eulw6oTHUb Ce4iit/IijBl9oOwkPoxB22WKCtellPyEQIhNU+gtEoK3XJ+sFe0Z8cI/8ZewlLAveaB 1WmQ== X-Received: by 10.68.197.131 with SMTP id iu3mr7627608pbc.72.1360465793090; Sat, 09 Feb 2013 19:09:53 -0800 (PST) Received: from tsparkle (cm126.delta178.maxonline.com.sg. [59.189.178.126]) by mx.google.com with ESMTPS id xg1sm3190641pbc.26.2013.02.09.19.09.49 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sat, 09 Feb 2013 19:09:51 -0800 (PST) From: Chong Yidong To: Stefan Monnier Subject: Re: bug#4533: 23.1: reverting fails to update line ending mode line References: <1afaf6160909221901p527cca80jcbf81e589cde629d@mail.gmail.com> <87mxpcc115.fsf@stupidchicken.com> <87bp5qbipg.fsf@stupidchicken.com> Date: Sun, 10 Feb 2013 11:09:51 +0800 In-Reply-To: <87bp5qbipg.fsf@stupidchicken.com> (Chong Yidong's message of "Mon, 15 Nov 2010 12:27:39 -0500") Message-ID: <87zjzc3lvk.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.93 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 4533-done Cc: Kenichi Handa , 4533-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) Chong Yidong writes: >> So maybe the problem is that C-x C-s should not set >> buffer-file-coding-system-explicit (unless the C-x C-s prompted the user >> to choose a coding-system, I guess). > > I see. The comments in mule.el say that > > ;; This variable is set in these three cases: > ;; (1) A file is read by a coding system specified explicitly. > ;; after-insert-file-set-coding sets the car of this value to > ;; coding-system-for-read, and sets the cdr to nil. > ;; (2) A buffer is saved. > ;; After writing, basic-save-buffer-1 sets the car of this value > ;; to last-coding-system-used. > ;; (3) set-buffer-file-coding-system is called. > ;; The cdr of this value is set to the specified coding system. > ;; This variable is used for decoding in revert-buffer and encoding in > ;; select-safe-coding-system. > > Indeed, this seems to imply that (2) can be omitted, as you suggest, > since "force selecting" a coding system should trigger (1) and (3). Is > there any reason that (2) was originally included? Since there's been no response, and my testing showed no ill effects to this change, I went ahead and committed it in the trunk. Let's see how it shakes out. ------------=_1360465869-2559-3 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 22 Dec 2012 23:58:27 +0000 Received: from localhost ([127.0.0.1]:55993 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TmYxW-0007jW-9q for submit@debbugs.gnu.org; Sat, 22 Dec 2012 18:58:27 -0500 Received: from eggs.gnu.org ([208.118.235.92]:41128) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TmYxS-0007jN-VP for submit@debbugs.gnu.org; Sat, 22 Dec 2012 18:58:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TmYx0-0008Pr-0h for submit@debbugs.gnu.org; Sat, 22 Dec 2012 18:58:01 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-104.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, USER_IN_WHITELIST autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:57933) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TmYwz-0008Pn-TV for submit@debbugs.gnu.org; Sat, 22 Dec 2012 18:57:53 -0500 Received: from eggs.gnu.org ([208.118.235.92]:52455) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TmYwt-0006XK-0R for bug-gnu-emacs@gnu.org; Sat, 22 Dec 2012 18:57:53 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TmYwm-0008Nn-2O for bug-gnu-emacs@gnu.org; Sat, 22 Dec 2012 18:57:46 -0500 Received: from exprod7og124.obsmtp.com ([64.18.2.26]:53923) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1TmYwl-0008Nb-Lk for bug-gnu-emacs@gnu.org; Sat, 22 Dec 2012 18:57:39 -0500 Received: from mail-bk0-f69.google.com ([209.85.214.69]) (using TLSv1) by exprod7ob124.postini.com ([64.18.6.12]) with SMTP ID DSNKUNZI8FFyTP44MHDEelsBDzY6iNHgS7Mb@postini.com; Sat, 22 Dec 2012 15:57:39 PST Received: by mail-bk0-f69.google.com with SMTP id jg9so4931415bkc.8 for ; Sat, 22 Dec 2012 15:57:35 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-received:from:to:subject:date:message-id:mime-version :content-type:content-transfer-encoding:x-gm-message-state; bh=7qqRBkhOT5Yj0HlYKKgs9XRJ35FH3243uH5Z7+fi72c=; b=OAj/cgqqFad/FDO7UofBBhRKJk9h7uiuGGWvi5wLh15I5xXm0CXseWrwljBztoVVAd yhNmmGZUKU7M9RAJZ3gqNG6INJuTWRmCBZdYode8bzT7WAL/3Sl/MXpxOzwwcsMsLrL9 5S/DnDMACzDKOrZYt7v09phpADE+T1J+g9dfZ2mjLsHXOE0SqNalNQvP6HpqmF3g3mMP 7iowyhQta9j3Nq8WSjLPKMNY8wU0li98q2Tc7w9UabezjgsQ5SEzYojj2lxY0cwsdlC1 aErMrXVzhm+80fNxad2ET8HdiCcgjEF9w/q+TdCMEL6hVwpsAV1H+o8HX/KGB2SdnXOu 03xw== X-Received: by 10.194.78.162 with SMTP id c2mr29843110wjx.46.1356220655295; Sat, 22 Dec 2012 15:57:35 -0800 (PST) X-Received: by 10.194.78.162 with SMTP id c2mr29843108wjx.46.1356220655189; Sat, 22 Dec 2012 15:57:35 -0800 (PST) Received: from slice ([149.241.102.247]) by mx.google.com with ESMTPS id w5sm36546777wif.11.2012.12.22.15.57.34 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 22 Dec 2012 15:57:34 -0800 (PST) From: Reuben Thomas To: bug-gnu-emacs@gnu.org Subject: 24.1; auto-revert does not re-check encoding Date: Sat, 22 Dec 2012 23:57:33 +0000 Message-ID: <87wqw9r66q.fsf@sc3d.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Gm-Message-State: ALoCoQmltYw9qunMAunwVFBmr4lpr1FxLUr97uUal1BTtBwUklSS4s/PPFhjNJ32YaaA4deR5M1K9LJ0Pro/lzURPJpvFa2MOzlkJSCTRl66211GJgomC+6RAziIUovz3WZEF16SmuvlPcYCkIAdV6m8ickIOoO0GOj/YMFG89G7uG33o4ciHtQ= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -6.2 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.2 (------) I use auto-revert-mode. If I run e.g. dos2unix on a buffer I'm editing, it is reverted, but Emacs does not notice that the line ending encoding has changed. Hence, continuing to edit and re-saving will undo the unix2dos command. In GNU Emacs 24.1.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.12) of 2012-09-22 on batsu, modified by Debian Windowing system distributor `The X.Org Foundation', version 11.0.11300000 Configured using: `configure '--build' 'x86_64-linux-gnu' '--build' 'x86_64-linux-gnu' '--prefix=3D/usr' '--sharedstatedir=3D/var/lib' '--libexecdir=3D/usr/lib' '--localstatedir=3D/var/lib' '--infodir=3D/usr/share/info' '--mandir=3D/usr/share/man' '--with-pop=3Dyes' '--enable-locallisppath=3D/etc/emacs24:/etc/emacs:/usr/local/share/emacs/2= 4.1/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/24.1/site-l= isp:/usr/share/emacs/site-lisp' '--with-crt-dir=3D/usr/lib/x86_64-linux-gnu' '--with-x=3Dyes' '--with-x-toolkit=3Dgtk' '--with-toolkit-scroll-bars' 'build_alias=3Dx86_64-linux-gnu' 'CFLAGS=3D-g -O2 -fstack-protector --param=3Dssp-buffer-size=3D4 -Wformat -Werror=3Dformat-security -Wall -O2' 'CPPFLAGS=3D-D_FORTIFY_SOURCE=3D2'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: en_GB.UTF-8 value of $LC_NUMERIC: en_GB.UTF-8 value of $LC_TIME: en_GB.UTF-8 value of $LANG: en_GB.UTF-8 value of $XMODIFIERS: @im=3Dnone locale-coding-system: utf-8-unix default enable-multibyte-characters: t Major mode: Text Minor modes in effect: diff-auto-refine-mode: t TeX-PDF-mode: t shell-dirtrack-mode: t buffer-face-mode: t flyspell-mode: t smart-quotes-mode: t recentf-mode: t show-paren-mode: t server-mode: t savehist-mode: t minibuffer-electric-default-mode: t iswitchb-mode: t icomplete-mode: t global-auto-revert-mode: t desktop-save-mode: t tooltip-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t Recent input: C-x C-s C-c C-c M-< C-s e d l=20 a b e l C-a C-s b a r e l y =20 C-s C-s C-s C-s C-s C-s C-s C-s C-s C-s=20 i s SPC b u t M-d =20 =20 =20 =20 a n d SPC t h i r t y y - s i x SPC C-x=20 C-s C-c C-c C-s p u n SPC o n SPC C-a =20 =20 =20 =20 =20 ) C-x C-s C-c C-c =20 C-x C-f ~ / N o t e T h i n g L e =20 C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n=20 C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n=20 C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n I r i a=20 : S-SPC A =E2=80=93 Z . C-x C-s =20 =20 =20 =20 =20 C-x C-s =20 G r a m p s C-x C-s C-n C-n C-n C-n C-n C-n C-n C-n=20 C-n C-n C-n C-n C-n C-n C-n C-n C-n C-x k =20 C-x C-f M-> M-< M-> M-x r e p o r t b=20 u - e m a c s - b u g Recent messages: byte-code: End of buffer [27 times] Saving file /home/rrt/Notes/Things Lent... Wrote /home/rrt/Notes/Things Lent Saving file /home/rrt/Notes/Things Lent... Wrote /home/rrt/Notes/Things Lent Saving file /home/rrt/Notes/Things Lent... Wrote /home/rrt/Notes/Things Lent Reverting buffer `Things Lent'. byte-code: End of buffer [10 times] Mark set [3 times] Load-path shadows: /home/rrt/local/share/emacs/site-lisp/dict hides /usr/share/emacs24/site-li= sp/emacs-goodies-el/dict /home/rrt/local/share/emacs/site-lisp/browse-kill-ring hides /usr/share/ema= cs24/site-lisp/emacs-goodies-el/browse-kill-ring /home/rrt/.emacs.d/elpa/dictionary-1.8.7/link hides /usr/share/emacs24/site= -lisp/dictionary-el/link /home/rrt/.emacs.d/elpa/dictionary-1.8.7/dictionary hides /usr/share/emacs2= 4/site-lisp/dictionary-el/dictionary /home/rrt/.emacs.d/elpa/dictionary-1.8.7/dictionary-init hides /usr/share/e= macs24/site-lisp/dictionary-el/dictionary-init /home/rrt/.emacs.d/elpa/dictionary-1.8.7/connection hides /usr/share/emacs2= 4/site-lisp/dictionary-el/connection /usr/share/emacs24/site-lisp/auctex/multi-prompt hides /usr/share/emacs/sit= e-lisp/auctex/multi-prompt /usr/share/emacs24/site-lisp/auctex/latex hides /usr/share/emacs/site-lisp/= auctex/latex /usr/share/emacs24/site-lisp/auctex/texmathp hides /usr/share/emacs/site-li= sp/auctex/texmathp /usr/share/emacs24/site-lisp/auctex/tex-fold hides /usr/share/emacs/site-li= sp/auctex/tex-fold /usr/share/emacs24/site-lisp/auctex/tex-jp hides /usr/share/emacs/site-lisp= /auctex/tex-jp /usr/share/emacs24/site-lisp/auctex/preview hides /usr/share/emacs/site-lis= p/auctex/preview /usr/share/emacs24/site-lisp/auctex/tex-bar hides /usr/share/emacs/site-lis= p/auctex/tex-bar /usr/share/emacs24/site-lisp/auctex/tex-mik hides /usr/share/emacs/site-lis= p/auctex/tex-mik /usr/share/emacs24/site-lisp/auctex/toolbar-x hides /usr/share/emacs/site-l= isp/auctex/toolbar-x /usr/share/emacs24/site-lisp/auctex/tex hides /usr/share/emacs/site-lisp/au= ctex/tex /usr/share/emacs24/site-lisp/auctex/prv-emacs hides /usr/share/emacs/site-l= isp/auctex/prv-emacs /usr/share/emacs24/site-lisp/auctex/context hides /usr/share/emacs/site-lis= p/auctex/context /usr/share/emacs24/site-lisp/auctex/tex-info hides /usr/share/emacs/site-li= sp/auctex/tex-info /usr/share/emacs24/site-lisp/auctex/tex-font hides /usr/share/emacs/site-li= sp/auctex/tex-font /usr/share/emacs24/site-lisp/auctex/tex-style hides /usr/share/emacs/site-l= isp/auctex/tex-style /usr/share/emacs24/site-lisp/auctex/bib-cite hides /usr/share/emacs/site-li= sp/auctex/bib-cite /usr/share/emacs24/site-lisp/auctex/font-latex hides /usr/share/emacs/site-= lisp/auctex/font-latex /usr/share/emacs24/site-lisp/auctex/context-nl hides /usr/share/emacs/site-= lisp/auctex/context-nl /usr/share/emacs24/site-lisp/auctex/plain-tex hides /usr/share/emacs/site-l= isp/auctex/plain-tex /usr/share/emacs24/site-lisp/auctex/context-en hides /usr/share/emacs/site-= lisp/auctex/context-en /usr/share/emacs24/site-lisp/auctex/tex-buf hides /usr/share/emacs/site-lis= p/auctex/tex-buf /usr/share/emacs/site-lisp/golang-mode/go-mode-load hides /usr/share/emacs/= 24.1/site-lisp/golang-mode/go-mode-load /usr/share/emacs/site-lisp/golang-mode/go-mode hides /usr/share/emacs/24.1/= site-lisp/golang-mode/go-mode /usr/share/emacs/24.1/site-lisp/cmake-data/cmake-mode hides /usr/share/emac= s/site-lisp/cmake-mode /usr/share/emacs24/site-lisp/dictionaries-common/ispell hides /usr/share/em= acs/24.1/lisp/textmodes/ispell /usr/share/emacs24/site-lisp/dictionaries-common/flyspell hides /usr/share/= emacs/24.1/lisp/textmodes/flyspell /usr/share/emacs/site-lisp/rst hides /usr/share/emacs/24.1/lisp/textmodes/r= st Features: (shadow sort gnus-util mail-extr emacsbug message format-spec rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils thai-util thai-word mule-util lao-util js json imenu sgml-mode locate thingatpt browse-url doc-view jka-compr image-mode dired ps-mode diff-git diff-mode log-edit pcvs-util add-log vc ediff-merg ediff-diff ediff-wind ediff-help ediff-util ediff-mult ediff-init ediff vc-dispatcher texmathp preview prv-emacs warnings tex-buf noutline outline font-latex byte-opt bytecomp byte-compile cconv macroexp latex tex-style tex dbus xml latexenc sh-script executable shell pcomplete grep etags newcomment multi-isearch help-mode view nroff-mode autoconf autoconf-mode inform-mode make-mode cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs flymake compile comint ansi-color ring vc-git face-remap regexp-opt flyspell ispell smart-quotes cperl-mode auto-dictionary-autoloads c-eldoc-autoloads dictionary-autoloads diff-git-autoloads dired-isearch-autoloads full-ack-autoloads guess-style-autoloads kill-ring-search-autoloads magit-autoloads mv-shell-autoloads tumble-autoloads http-post-simple-autoloads package tabulated-list completing-help recentf tree-widget wid-edit uniquify paren server savehist minibuf-eldef iswitchb icomplete autorevert desktop cus-start cus-load ropemacs pymacs user-site-loaddefs advice advice-preload yasnippet help-fns derived edmacro kmacro easymenu assoc cl go-mode-load emacs-goodies-el emacs-goodies-custom emacs-goodies-loaddefs easy-mmode preview-latex tex-site auto-loads time-date tooltip ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image fringe lisp-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces cus-face files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process dbusbind dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs) --=20 http://rrt.sc3d.org/ ------------=_1360465869-2559-3--