From: Zhang Haijun <ccsmile2008@outlook.com>
To: "emacs-devel@gnu.org" <emacs-devel@gnu.org>
Subject: 26.1.50; Emacs can't decode the text file on opening the file, but can decode it on revert-buffer
Date: Sun, 4 Nov 2018 08:44:36 +0000 [thread overview]
Message-ID: <SG2PR0601MB1405441899781F1B66EC1707A8C90@SG2PR0601MB1405.apcprd06.prod.outlook.com> (raw)
I have sent a bug report mail to bug-gnu-emacs@gnu.org, but didn't
receive the bug number mail. So I send it here.
I put the attachment file to: http://119.37.194.6/upload/tmp/emacs-26.txt
Following is the bug report mail:
Open the attachment text file with "emacs -Q". There are many
unrecognized chars(like \342\200\230). Following is the encoding info of
the buffer.
-------------------------------------------------
= -- no-conversion (alias: binary)
Do no conversion.
When you visit a file with this coding, the file is read into a
unibyte buffer as is, thus each byte of a file is treated as a
character.
Type: raw-text (text with random binary characters)
EOL type: LF
--------------------------------------------------
But if I run the command revert-buffer, then there is no unrecognized
chars. Encoding info of the buffer becomes:
---------------------------------------------------
U -- utf-8-unix (alias: mule-utf-8-unix cp65001-unix)
UTF-8 (no signature (BOM))
Type: utf-8 (UTF-8: Emacs internal multibyte form)
EOL type: LF
This coding system encodes the following charsets:
unicode
---------------------------------------------------
In GNU Emacs 26.1.50 (build 4, x86_64-pc-linux-gnu, GTK+ Version 3.22.26)
of 2018-11-04 built on centos7.home
Repository revision: 7cadb328092e354225149bbc74c2ddaf4b49b638
Windowing system distributor 'The X.Org Foundation', version 11.0.11905000
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Quit [3 times]
user-error: Beginning of history; no preceding item
funcall-interactively: End of buffer
Configured using:
'configure --prefix=/home/jun/apps/emacs-26 --without-makeinfo
--with-x-toolkit=gtk3 --with-modules'
Configured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND DBUS GSETTINGS GLIB NOTIFY
LIBSELINUX GNUTLS LIBXML2 FREETYPE XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11
XDBE XIM MODULES THREADS
Important settings:
value of $LANG: en_US.UTF-8
value of $XMODIFIERS: @im=fcitx
locale-coding-system: utf-8-unix
Major mode: Text
Minor modes in effect:
diff-auto-refine-mode: t
tooltip-mode: t
global-eldoc-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-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
line-number-mode: t
transient-mark-mode: t
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message rmc puny seq byte-opt gv
bytecomp byte-compile cconv cl-loaddefs cl-lib dired dired-loaddefs
format-spec rfc822 mml mml-sec password-cache epa derived epg epg-config
gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse
rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045
ietf-drums mm-util mail-prsvr mail-utils vc-git diff-mode easymenu
easy-mmode elec-pair time-date mule-util tooltip eldoc electric uniquify
ediff-hook vc-hooks lisp-float-type mwheel term/x-win x-win
term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace newcomment text-mode elisp-mode lisp-mode
prog-mode register page menu-bar rfn-eshadow isearch timer select
scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european ethiopic indian cyrillic
chinese composite charscript charprop case-table epa-hook jka-cmpr-hook
help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote threads dbusbind inotify dynamic-setting system-font-setting
font-render-setting move-toolbar gtk x-toolkit x multi-tty
make-network-process emacs)
Memory information:
((conses 16 98466 14078)
(symbols 48 20784 1)
(miscs 40 42 154)
(strings 32 29892 1511)
(string-bytes 1 791061)
(vectors 16 14723)
(vector-slots 8 510132 7238)
(floats 8 51 372)
(intervals 56 222 0)
(buffers 992 13)
(heap 1024 24474 3071))
next reply other threads:[~2018-11-04 8:44 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-04 8:44 Zhang Haijun [this message]
2018-11-04 9:18 ` 26.1.50; Emacs can't decode the text file on opening the file, but can decode it on revert-buffer Eli Zaretskii
[not found] ` <16B3CA28-C893-4854-AD64-1C224C1EDDB2@outlook.com>
2018-11-04 14:49 ` Eli Zaretskii
[not found] ` <B213388B-58E6-4F5B-8CE8-79AC5AD3062B@outlook.com>
2018-11-04 17:13 ` Eli Zaretskii
2018-11-05 8:59 ` Zhang Haijun
2018-11-05 9:00 ` Zhang Haijun
2018-11-05 9:00 ` Zhang Haijun
2018-11-05 9:39 ` Phil Sainty
2018-11-05 10:10 ` Stephen Berman
2018-11-05 14:08 ` Zhang Haijun
2018-11-05 15:02 ` Stephen Berman
2018-11-05 16:00 ` Eli Zaretskii
2018-11-06 1:39 ` Zhang Haijun
2018-11-06 3:31 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=SG2PR0601MB1405441899781F1B66EC1707A8C90@SG2PR0601MB1405.apcprd06.prod.outlook.com \
--to=ccsmile2008@outlook.com \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.