emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Saving safe local variables garbles 8-bit characters in .emacs file


From: Ralf Angeli
Subject: Saving safe local variables garbles 8-bit characters in .emacs file
Date: Mon, 06 Mar 2006 17:38:32 +0100

Under certain circumstances saving safe local variables permanently,
i.e. answering with `!' to the respective question may garble 8-bit
characters in a .emacs file.  For this to happen the .emacs file has
to contain UTF-8 characters and has to be saved as UTF-8.  In addition
Emacs has to be started in a directory with a .emacs.desktop file
which has to load a LaTeX file containing 8-bit characters like
umlauts, i.e. a file with a Latin-1 coding system.  In addition the
LaTeX file has to contain a Local Variables section with an unknown
variable.  As soon as Emacs is started this should pop up the question
about how to deal with the variable and once you answer with `!' the
.emacs file will be written.  If you open the .emacs file after that
8-bit characters will be garbled (it looks like the UTF-8 characters
got decomposed into their two separate bytes).

Attached you can find the files I used for testing (".emacs.orig" is
the original .emacs file and ".emacs.result" the one after the safe
variables stuff was written to it):

Attachment: .emacs.orig
Description: Text document

Attachment: .emacs.result
Description: Text document

Attachment: .emacs.desktop
Description: Text document

Attachment: test.tex
Description: Text document



In GNU Emacs 22.0.50.1 (i686-pc-linux-gnu, GTK+ Version 2.8.13)
 of 2006-03-06 on neutrino
X server distributor `The X.Org Foundation', version 11.0.60802000
configured using `configure '--with-gtk''

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-8859-1
  default-enable-multibyte-characters: t

Major mode: Emacs-Lisp

Minor modes in effect:
  desktop-save-mode: t
  tooltip-mode: t
  auto-compression-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
  unify-8859-on-encoding-mode: t
  utf-translate-cjk-mode: t
  line-number-mode: t

Recent input:
! C-x C-f <C-backspace> <C-backspace> <C-backspace> 
. e m <tab> <return> M-x r e p o r <tab> <return>

Recent messages:
Loading regexp-opt...done
Loading tex-mode...done
Please type y, n, or !: 
Loading cus-edit...
Loading easymenu...done
Loading cus-edit...done
Wrote /home/angeli/.emacs
Desktop: 1 buffer restored.
For information about the GNU Project and its goals, type C-h C-p.
Loading emacsbug...done

reply via email to

[Prev in Thread] Current Thread [Next in Thread]