Bug 126007 - European chars interpreted as prefixes and emacs loops on console
European chars interpreted as prefixes and emacs loops on console
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: emacs (Show other bugs)
rawhide
i386 Linux
medium Severity high
: ---
: ---
Assigned To: Jens Petersen
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-06-15 04:13 EDT by Eddahbi Karim
Modified: 2007-11-30 17:10 EST (History)
2 users (show)

See Also:
Fixed In Version: 21.3-24
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-09-04 20:25:43 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
emacs-kbd-coding.patch (567 bytes, patch)
2005-02-24 08:22 EST, Jens Petersen
no flags Details | Diff

  None (edit)
Description Eddahbi Karim 2004-06-15 04:13:20 EDT
Description of problem:
The French character î makes emacs freeze when using it in a real
terminal (CTRL+ALT+F1).

Version-Release number of selected component (if applicable):
GNU Emacs 21.3.1

How reproducible:
Always for me

Steps to Reproduce:
1. Use the fonts "latarcyrheb-sun16" with your terminal ($ setfont
latarcyrheb-sun16)
2. Launch emacs then create a temporary text file ($ emacs test)
3. Type ^ i (Because you want to type a î)
  
Actual results:
Emacs will freeze and use 96% of CPU

Expected results:
Prints a î

Additional info:
It doesn't occur with the fonts lat9w-16 but with these fonts, 'î' is
taken like a macro-key (similar to C-, M-)
Comment 1 Jens Petersen 2004-09-29 12:15:34 EDT
"^i" works outside emacs?
Comment 2 Eddahbi Karim 2004-09-29 17:16:03 EDT
Yeah, it works. It just displays nothing but it works...
Comment 3 Jens Petersen 2004-10-06 03:38:33 EDT
Do I need to use a French kbd layout to reproduce this?

Can you explain exactly how to enter "^ i" in Emacs?
Comment 4 Jens Petersen 2004-10-06 04:15:18 EDT
Nevermind, I managed to input ^i with a French kbd layout.

Yep, I see it is interpreted as a prefix key by Emacs
but it doesn't emacs to freeze for me or use all the cpu.
Nor do the other accented letters.  However I'm testing
with a FC devel (rawhide).  Any chance you could test with
that? :)
Comment 5 Eddahbi Karim 2004-10-07 03:42:23 EDT
Did you have the same keyboard layout, fonts (latarcyrheb-sun16) and
charset (fr_FR.UTF8) ?
Are you using a xterm or a real terminal ? It seems to occurs only in
real terminals.

The first time I got this problem, it was with a fresh installation of
Fedora Core 2, using a french setup and the problem still occured with
rawhide packets, last time I checked.

If I find a friend with a Fedora Core 2 installed, I'll ask him to try
it...

I'll try with the latest Rawhide when I can.
Thanks for the help ;)
Comment 6 John Smith 2005-02-09 19:02:39 EST
I have a problem which I think is related to this one, although
it has nothing to do with the linux console, the font or the
keymap.

Launch emacs (under X), then type:
C-x 8 ' e f o o b a r

Well here it makes emacs freeze and eat 98% of cpu before you
can even finish to type foobar. (You can unfreeze it with C-g,
though.)
Comment 7 Pawel Salek 2005-02-22 05:39:18 EST
I see similar problem when I ssh from OSX to FC3 and type one of Swedish
characters, eg "ä" (use dead keys to construct it). Ctrl-G will not stop the loop.
Comment 8 Jens Petersen 2005-02-24 05:17:58 EST
Yes, I can reproduce î and "C-x 8 ' e" being interpreted as a modifiers.
And on the console causing looping, which C-g breaks out of it.

I can't reproduce with "emacs --no-site-file" though:
it seems it is caused by the (set-keyboard-coding-system 'utf-8)
setting in lang-coding-systems-init.el (see bug 106929) afaict.
Comment 9 Jens Petersen 2005-02-24 05:57:18 EST
Worse, it seems (set-keyboard-coding-system 'utf-8)
is needed for Latin input in a terminal, but this
breaks input on the console.  So probably need to
condition this on the value of TERM I guess.
Comment 10 Jens Petersen 2005-02-24 08:22:43 EST
Created attachment 111375 [details]
emacs-kbd-coding.patch

I believe this change basically fixes the problem.
Could you please test it and if it is good, I'll
update emacs with it.
Comment 11 Jens Petersen 2005-02-25 08:34:18 EST
The above fix appears to 21.3-24.
Could you please confirm if this fixes the issue?
Comment 12 Pawel Salek 2005-02-25 14:50:43 EST
I have tested the patch and it appears to fix the issue - thanks!
Comment 13 Rahul Sundaram 2005-09-04 20:25:43 EDT
Closing as per previous comment

Note You need to log in before you can comment on or make changes to this bug.