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

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

Re: prefix keymap echoing partly broken


From: Reiner Steib
Subject: Re: prefix keymap echoing partly broken
Date: Fri, 18 Mar 2005 14:02:23 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

On Thu, Mar 17 2005, Richard Stallman wrote:

>     It fails here as well (GTK or tty) with "emacs -Q" (updated and built
>     10 hours, the same with a built from 2005-03-07).  If I don't wait for
>     the `C-x-' echo to appear, it displays `C-x RET-'.
>
> If it fails for you, can you debug it?

I tried.  But I'm not familiar with C debugging, so I don't know if my
findings are helpful.  (BTW: In Emacs 21.4, the bug doesn't exist.)

Here is a backtrace from the "fast" sequence, i.e. `C-x RET-' is
displayed (I sent "kill -TSTP" to the process):

--8<---------------cut here---------------start------------->8---
(gdb) bt
#0  0x0000002a974a42a5 in __select_nocancel () from /lib64/tls/libc.so.6
#1  0x0000000000580391 in wait_reading_process_output (time_limit=30, 
microsecs=0, read_kbd=-1, do_display=1, 
    wait_for_cell=9609249, wait_proc=0x0, just_wait_proc=0)
    at [...]/emacs/src/process.c:4350
#2  0x000000000044a551 in sit_for (sec=30, usec=0, reading=1, display=1, 
initial_display=0)
    at [...]/emacs/src/dispnew.c:6367
#3  0x00000000004f0528 in read_char (commandflag=1, nmaps=2, maps=0x7fbfffd570, 
prev_event=104, 
    used_mouse_menu=0x7fbfffd5e4) at [...]/emacs/src/keyboard.c:2769
#4  0x00000000004f26f6 in read_key_sequence (keybuf=0x7fbfffd780, bufsize=30, 
prompt=9609249, 
    dont_downcase_last=0, can_return_switch_frame=1, fix_current_buffer=1)
    at [...]/emacs/src/keyboard.c:8803
#5  0x00000000004f431d in command_loop_1 () at [...]/emacs/src/keyboard.c:1538
#6  0x000000000054c851 in internal_condition_case (bfun=0x4f4180 
<command_loop_1>, handlers=9720769, 
    hfun=0x4ee7c0 <cmd_error>) at [...]/emacs/src/eval.c:1385
#7  0x00000000004eda4a in command_loop_2 () at [...]/emacs/src/keyboard.c:1319
#8  0x000000000054c9a0 in internal_catch (tag=Variable "tag" is not available.
) at [...]/emacs/src/eval.c:1144
#9  0x00000000004ee458 in command_loop () at [...]/emacs/src/keyboard.c:1298
#10 0x00000000004ee4f1 in recursive_edit_1 () at [...]/emacs/src/keyboard.c:991
#11 0x00000000004ee61e in Frecursive_edit () at [...]/emacs/src/keyboard.c:1052
#12 0x00000000004e3e1d in main (argc=2, argv=0x7fbfffe008)
    at [...]/emacs/src/emacs.c:1767
--8<---------------cut here---------------end--------------->8---

And this is a backtrace from the "slow" sequence, i.e. `C-x RET' is
displayed with the dash:

--8<---------------cut here---------------start------------->8---
(gdb) bt
#0  0x0000002a974a42a5 in __select_nocancel () from /lib64/tls/libc.so.6
#1  0x0000000000580391 in wait_reading_process_output (time_limit=0, 
microsecs=0, read_kbd=-1, do_display=1, 
    wait_for_cell=9609249, wait_proc=0x0, just_wait_proc=0)
    at [...]/emacs/src/process.c:4350
#2  0x00000000004efd7b in read_char (commandflag=1, nmaps=2, maps=0x7fbfffd570, 
prev_event=104, 
    used_mouse_menu=0x7fbfffd5e4) at [...]/emacs/src/keyboard.c:3917
#3  0x00000000004f26f6 in read_key_sequence (keybuf=0x7fbfffd780, bufsize=30, 
prompt=9609249, 
    dont_downcase_last=0, can_return_switch_frame=1, fix_current_buffer=1)
    at [...]/emacs/src/keyboard.c:8803
#4  0x00000000004f431d in command_loop_1 () at [...]/emacs/src/keyboard.c:1538
#5  0x000000000054c851 in internal_condition_case (bfun=0x4f4180 
<command_loop_1>, handlers=9720769, 
    hfun=0x4ee7c0 <cmd_error>) at [...]/emacs/src/eval.c:1385
#6  0x00000000004eda4a in command_loop_2 () at [...]/emacs/src/keyboard.c:1319
#7  0x000000000054c9a0 in internal_catch (tag=Variable "tag" is not available.
) at [...]/emacs/src/eval.c:1144
#8  0x00000000004ee458 in command_loop () at [...]/emacs/src/keyboard.c:1298
#9  0x00000000004ee4f1 in recursive_edit_1 () at [...]/emacs/src/keyboard.c:991
#10 0x00000000004ee61e in Frecursive_edit () at [...]/emacs/src/keyboard.c:1052
#11 0x00000000004e3e1d in main (argc=2, argv=0x7fbfffe008)
    at [...]/emacs/src/emacs.c:1767
--8<---------------cut here---------------end--------------->8---

Is far as I understand, the dash is supposed to be produced by
echo_dash() in read_char() (keyboard.c:2592).  Within read_char(),
echo_dash() is only called at this line.  Maybe this statement isn't
reached, because there is already `C-x' in the echo area as the
comment indicates:

--8<---------------cut here---------------start------------->8---
  if (/* There currently is something in the echo area.  */
      !NILP (echo_area_buffer[0])
      && (/* And it's either not from echoing.  */
          !EQ (echo_area_buffer[0], echo_message_buffer)
          /* Or it's an echo from a different kboard.  */
          || echo_kboard != current_kboard
          /* Or we explicitly allow overwriting whatever there is.  */
          || ok_to_echo_at_next_pause == NULL))
    cancel_echoing ();
  else
    echo_dash ();
--8<---------------cut here---------------end--------------->8---

Bye, Reiner.
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/




reply via email to

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