all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Sven Joachim <svenjoac@gmx.de>
Cc: 5365@debbugs.gnu.org
Subject: bug#5365: 23.1.91; Wrong type argument: keymapp, ("DEAD" . 35215396)
Date: Wed, 13 Jan 2010 10:17:23 -0500	[thread overview]
Message-ID: <jwvfx6af40s.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <87ockyqq2c.fsf@turtle.gmx.de> (Sven Joachim's message of "Wed, 13 Jan 2010 11:03:55 +0100")

>> Today I've built and installed an emacs-snapshot package for Debian, and
>> I'm seeing this:
>> 
>> ,----
>> | % emacs -Q
>> | Wrong type argument: keymapp, ("DEAD" . 35215396)
>> | % echo $?
>> | 255
>> `----

This cons cell is almost for sure on the free-list.  I.e. the memory
management code thought it was unused and put it back on the free list
for reuse (and luckily it hasn't been reused yet).

This implies that a backtrace probably won't be sufficient to track it
down :-(

>> Unfortunately this is a Heisenbug, I'm not able to reproduce it under
>> gdb.

> I now managed to attach gdb to a running process and get a backtrace
> after setting a breakpoint on Fsignal:

> | Lisp Backtrace:
> | "keymap-parent" (0xffa14acc)
> | "x-setup-function-keys" (0xffa14c34)
> | "x-create-frame-with-faces" (0xffa14db4)
> | "make-frame" (0xffa14f34)
> | "frame-initialize" (0xffa150b4)
> | "command-line" (0xffa15234)
> | "normal-top-level" (0xffa15330)
> | (gdb)

OK, so if we trust your backtrace (if you compiled with optimizations,
there's a good chance that some parts of the backtrace aren't to be
trusted, tho the Lisp part is less likely to be invented), the above
implies that we're looking at the (keymap-parent local-function-key-map)
call in x-win.el's x-setup-function-keys.

> ,----
> | (gdb) bt
> | #0  Fsignal (error_symbol=138366426, data=138990086) at eval.c:1629
> | #1  0x0818cfa8 in xsignal (error_symbol=138366426, data=138990086) at eval.c:1729
> | #2  0x0818d377 in xsignal2 (error_symbol=138366426, arg1=138358370, arg2=140861614) at eval.c:1753
> | #3  0x0817b0a1 in wrong_type_argument (predicate=138358370, value=140861614) at data.c:118
> | #4  0x081324a5 in get_keymap (object=140861614, error=1, autoload=1) at keymap.c:307
> | #5  0x08132d32 in keymap_parent (keymap=140861614, autoload=1) at keymap.c:321
> | #6  0x08132dc9 in Fkeymap_parent (keymap=140861614) at keymap.c:341

And this seems to indicate that the free cons cell ("DEAD" . 35215396)
is actually the one we got from local-function-key-map.  As for how that
could happen...


        Stefan






  reply	other threads:[~2010-01-13 15:17 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-12 14:58 bug#5365: 23.1.91; Wrong type argument: keymapp, ("DEAD" . 35215396) Sven Joachim
2010-01-13 10:03 ` Sven Joachim
2010-01-13 15:17   ` Stefan Monnier [this message]
2010-01-13 17:11     ` Chong Yidong
2010-01-13 17:27       ` Chong Yidong
2010-01-13 18:57         ` Stefan Monnier
2010-01-13 20:53           ` Chong Yidong
2010-01-14  4:21             ` Stefan Monnier
2010-01-15 16:27               ` Chong Yidong
2010-01-15 17:52                 ` Stefan Monnier
2010-01-13 19:13         ` Sven Joachim
2010-01-13 18:46       ` Sven Joachim
  -- strict thread matches above, loose matches on Subject: below --
2010-01-12 19:08 Chong Yidong
2010-01-12 19:39 ` Sven Joachim

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=jwvfx6af40s.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=5365@debbugs.gnu.org \
    --cc=svenjoac@gmx.de \
    /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.