From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Miguel Frasson Newsgroups: gmane.emacs.bugs Subject: revert buffer does not change text file format (DOS, UNIX, etc) Date: Wed, 6 Aug 2003 12:23:25 +0200 (MEST) Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Message-ID: <20030806102325.8EEAD2F86@enquist.math.leidenuniv.nl> NNTP-Posting-Host: deer.gmane.org X-Trace: main.gmane.org 1060165464 29129 80.91.224.253 (6 Aug 2003 10:24:24 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 6 Aug 2003 10:24:24 +0000 (UTC) Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Aug 06 12:24:45 2003 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 19kLTJ-0004cx-00 for ; Wed, 06 Aug 2003 12:24:45 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.20) id 19kLSg-0005wL-LU for geb-bug-gnu-emacs@m.gmane.org; Wed, 06 Aug 2003 06:24:06 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.20) id 19kLSd-0005u8-Rj for bug-gnu-emacs@gnu.org; Wed, 06 Aug 2003 06:24:03 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.20) id 19kLS6-0005dh-79 for bug-gnu-emacs@gnu.org; Wed, 06 Aug 2003 06:24:01 -0400 Original-Received: from [132.229.231.22] (helo=mailgate.math.leidenuniv.nl) by monty-python.gnu.org with esmtp (Exim 4.20) id 19kLS5-0005ap-No for bug-gnu-emacs@gnu.org; Wed, 06 Aug 2003 06:23:29 -0400 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by mailgate.math.leidenuniv.nl (Postfix) with ESMTP id DF271ACA8 for ; Wed, 6 Aug 2003 12:23:27 +0200 (MEST) Original-Received: from mailgate.math.leidenuniv.nl ([127.0.0.1]) by localhost (mailgate [127.0.0.1:10024]) (amavisd-new) with ESMTP id 27417-09 for ; Wed, 6 Aug 2003 12:23:25 +0200 (MEST) Original-Received: from enquist.math.leidenuniv.nl (enquist.math.leidenuniv.nl [132.229.229.92]) by mailgate.math.leidenuniv.nl (Postfix) with ESMTP id C897DABF3 for ; Wed, 6 Aug 2003 12:23:25 +0200 (MEST) Original-Received: by enquist.math.leidenuniv.nl (Postfix, from userid 685) id 8EEAD2F86; Wed, 6 Aug 2003 12:23:25 +0200 (MEST) Original-To: bug-gnu-emacs@gnu.org X-Virus-Scanned: by amavisd-new X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.2 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: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.bugs:5488 X-Report-Spam: http://spam.gmane.org/gmane.emacs.bugs:5488 This bug report will be sent to the Free Software Foundation, not to your local site managers! Please write in English, because the Emacs maintainers do not have translators to read other languages for them. Your bug report will be posted to the bug-gnu-emacs@gnu.org mailing list, and to the gnu.emacs.bug news group. In GNU Emacs 21.2.1 (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2002-08-29 on astest configured using `configure --host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --target=i386-redhat-linux-gnu --program-prefix= --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man --infodir=/usr/share/info --with-gcc --with-pop --with-sound' 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: en_US locale-coding-system: iso-latin-1 default-enable-multibyte-characters: t Please describe exactly what actions triggered the bug and the precise symptoms of the bug: I had a (.tex) text file that was in DOS format (EOL is CRLF). When I open the file in emacs, I saw (DOS) in the status bar. On the terminal, I converted the file with program dos2unix (I wanted the file in this format). Back in emacs, I reverted the buffer, but the (DOS) status stayed. I exited emacs and opened the same file again, now *without* the (DOS) on the status bar. TO provide complete bug report, if I open file with DOS format on emacs, convert to unix, revert (status line does not change), convert again to DOS, revert again, then there is no change on status line in the whole process. Even more weird if I do the other way around. If I open with emacs a text file in unix format, then on terminal I convert it to dos format and I revert buffer, then the extra "..." (problably the carriage return character) appear in every end-of-line. Converting to unix again and reverting brings the file to "normal" state (no (DOS) on status line and without "..." on every EOL). Recent input: C-x C-f l a m a t h / l a r g e . t e x y e s y e s C-x k C-x C-f m a t h / l a r g e . t e x y e s y e s C-x 1 Recent messages: Updating environment menu... Sorting Removing duplicates... done Updating modify environment menu... Updating...done Loading mule-diag... Loading codepage...done Loading mule-diag...done Loading view...done Loading emacsbug...done