On Sep 14, 2005, at 8:51 AM, Jean-Marc Lasgouttes wrote:
The fact that it is related to key bindings is not too strange, since
the crash occurs in key-handling code. What is very strange, though,
is the following
#0 (anonymous namespace)::encode ([EMAIL PROTECTED], [EMAIL PROTECTED]) at
QLyXKeySym.C:59
#1 0x00174ca8 in QLyXKeySym::getISOEncoded (this=0xf947ab0,
[EMAIL PROTECTED]) at QLyXKeySym.C:200
See ho "encoding" has a reasonable-looking address in #1, but is @0x0
in #0. This does not seems possible according to the code for
getISOEncoded:
char QLyXKeySym::getISOEncoded(string const & encoding) const
{
if (lyxerr.debugging())
lyxerr[Debug::KEY] << "encoding is " << encoding << endl;
unsigned char const c = encode(encoding, text_);
if (lyxerr.debugging())
lyxerr[Debug::KEY] << "ISOEncoded returning value " << int
(c) << endl;
return c;
}
As you see, the variable "encoding" (which is constant anyway) is
passed unchanged.
Could this be a compiler bug? I guess you have the latest updates.
I do.
Could you try to compile without optimization
(--disable-optimization).
I still get a crash:
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000000
0x001682fc in (anonymous namespace)::encode ([EMAIL PROTECTED],
[EMAIL PROTECTED]) at QLyXKeySym.C:59
59 if (!codec->canEncode(str)) {
(gdb) bt
#0 0x001682fc in (anonymous namespace)::encode
([EMAIL PROTECTED], [EMAIL PROTECTED]) at QLyXKeySym.C:59
#1 0x00169518 in QLyXKeySym::getISOEncoded (this=0xf4706b0,
[EMAIL PROTECTED]) at QLyXKeySym.C:200
#2 0x00062050 in LyXFunc::processKeySym (this=0xae500c0, keysym={px
= 0xf4706b0, pn = {pi_ = 0xae19570}}, state=ctrl) at lyxfunc.C:248
#3 0x00007948 in BufferView::Pimpl::workAreaKeyPress
(this=0xae50820, key={px = 0xf4706b0, pn = {pi_ = 0xae19570}},
state=ctrl) at BufferView_pimpl.C:541
#4 0x006661dc in boost::_mfi::mf2<void, BufferView::Pimpl,
boost::shared_ptr<LyXKeySym>, key_modifier::state>::operator()
(this=0xc0734a0, p=0xae50820, a1={px = 0xf4706b0, pn = {pi_ =
0xae19570}}, a2=ctrl) at ../boost/boost/bind/mem_fn_template.hpp:252
#5 0x00664d64 in
boost::_bi::list3<boost::_bi::value<BufferView::Pimpl*>,
boost::arg<1>, boost::arg<2> >::operator()<boost::_mfi::mf2<void,
BufferView::Pimpl, boost::shared_ptr<LyXKeySym>,
key_modifier::state>,
boost::_bi::list2<boost::shared_ptr<LyXKeySym>&,
key_modifier::state&> > (this=0xc0734a8, [EMAIL PROTECTED], [EMAIL PROTECTED])
at ../boost/boost/bind.hpp:346
#6 0x00663864 in boost::_bi::bind_t<void, boost::_mfi::mf2<void,
BufferView::Pimpl, boost::shared_ptr<LyXKeySym>,
key_modifier::state>,
boost::_bi::list3<boost::_bi::value<BufferView::Pimpl*>,
boost::arg<1>, boost::arg<2> > >::operator()
<boost::shared_ptr<LyXKeySym>, key_modifier::state> (this=0xc0734a0,
[EMAIL PROTECTED], [EMAIL PROTECTED]) at ../boost/boost/bind/
bind_template.hpp:44
#7 0x00660f64 in
boost::detail::function::void_function_obj_invoker2<boost::_bi::bind_t<v
oid, boost::_mfi::mf2<void, BufferView::Pimpl,
boost::shared_ptr<LyXKeySym>, key_modifier::state>,
boost::_bi::list3<boost::_bi::value<BufferView::Pimpl*>,
boost::arg<1>, boost::arg<2> > >, void, boost::shared_ptr<LyXKeySym>,
key_modifier::state>::invoke (function_obj_ptr={obj_ptr = 0xc0734a0,
const_obj_ptr = 0xc0734a0, func_ptr = 0xc0734a0, data = "\f"},
a0=Cannot access memory at address 0x0
) at ../boost/boost/function/function_template.hpp:128
#8 0x00888d4c in boost::function2<void,
boost::shared_ptr<LyXKeySym>, key_modifier::state,
std::allocator<void> >::operator() () at ../../../boost/boost/
function/function_template.hpp:581
#9 0x00888984 in
boost::signals::detail::call_bound2<void>::caller<boost::shared_ptr<LyXK
eySym>, key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >::operator()
<boost::signals::detail::connection_slot_pair> (this=0xbfffe798,
[EMAIL PROTECTED]) at ../../../boost/boost/signals/signal_template.hpp:119
#10 0x0088866c in
boost::signals::detail::slot_call_iterator<boost::signals::detail::call_
bound2<void>::caller<boost::shared_ptr<LyXKeySym>,
key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator>::dereference
(this=0xbfffe790) at ../../../boost/boost/signals/detail/
slot_call_iterator.hpp:68
#11 0x0088818c in
boost::iterator_core_access::dereference<boost::signals::detail::slot_ca
ll_iterator<boost::signals::detail::call_bound2<void>::caller<boost::sha
red_ptr<LyXKeySym>, key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator> > ([EMAIL PROTECTED])
at ../../../boost/boost/iterator/iterator_facade.hpp:516
#12 0x00887aec in
boost::iterator_facade<boost::signals::detail::slot_call_iterator<boost:
:signals::detail::call_bound2<void>::caller<boost::shared_ptr<LyXKeySym>
, key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator>,
boost::signals::detail::unusable, boost::single_pass_traversal_tag,
boost::signals::detail::unusable const&, int>::operator*
(this=0xbfffe790) at ../../../boost/boost/iterator/
iterator_facade.hpp:634
#13 0x00887128 in
boost::detail::postfix_increment_proxy<boost::signals::detail::slot_call
_iterator<boost::signals::detail::call_bound2<void>::caller<boost::share
d_ptr<LyXKeySym>, key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator>
>::postfix_increment_proxy (this=0xbfffe6f0, [EMAIL PROTECTED])
at ../../../boost/boost/iterator/iterator_facade.hpp:144
#14 0x008870f0 in
boost::detail::postfix_increment_proxy<boost::signals::detail::slot_call
_iterator<boost::signals::detail::call_bound2<void>::caller<boost::share
d_ptr<LyXKeySym>, key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator>
>::postfix_increment_proxy (this=0xbfffe6f0, [EMAIL PROTECTED])
at ../../../boost/boost/iterator/iterator_facade.hpp:144
#15 0x00886848 in boost::operator+
+<boost::signals::detail::slot_call_iterator<boost::signals::detail::cal
l_bound2<void>::caller<boost::shared_ptr<LyXKeySym>,
key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator>,
boost::signals::detail::unusable, boost::single_pass_traversal_tag,
boost::signals::detail::unusable const&, int> ([EMAIL PROTECTED])
at ../../../boost/boost/iterator/iterator_facade.hpp:732
#16 0x00885c40 in boost::last_value<void>::operator()
<boost::signals::detail::slot_call_iterator<boost::signals::detail::call
_bound2<void>::caller<boost::shared_ptr<LyXKeySym>,
key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator> > (this=0xae4c774,
first=
{<iterator_facade<boost::signals::detail::slot_call_iterator<boost::sign
als::detail::call_bound2<void>::caller<boost::shared_ptr<LyXKeySym>,
key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator>,boost::signals::detail:
:unusable,boost::single_pass_traversal_tag,const
boost::signals::detail::unusable&,int>> = {<No data fields>}, iter =
{<iterator_facade<boost::signals::detail::named_slot_map_iterator,boost:
:signals::detail::connection_slot_pair,boost::forward_traversal_tag,boos
t::signals::detail::connection_slot_pair&,int>> = {<No data fields>},
impl_ = {ptr = 0xf4bfeb0}}, end =
{<iterator_facade<boost::signals::detail::named_slot_map_iterator,boost:
:signals::detail::connection_slot_pair,boost::forward_traversal_tag,boos
t::signals::detail::connection_slot_pair&,int>> = {<No data fields>},
impl_ = {ptr = 0xf4bfec0}}, f = {args = 0xbfffe760}, cache = {px =
0x0, pn = {pi_ = 0x0}}}, last=
{<iterator_facade<boost::signals::detail::slot_call_iterator<boost::sign
als::detail::call_bound2<void>::caller<boost::shared_ptr<LyXKeySym>,
key_modifier::state, boost::function<void ()
(boost::shared_ptr<LyXKeySym>, key_modifier::state),
std::allocator<void> > >,
boost::signals::detail::named_slot_map_iterator>,boost::signals::detail:
:unusable,boost::single_pass_traversal_tag,const
boost::signals::detail::unusable&,int>> = {<No data fields>}, iter =
{<iterator_facade<boost::signals::detail::named_slot_map_iterator,boost:
:signals::detail::connection_slot_pair,boost::forward_traversal_tag,boos
t::signals::detail::connection_slot_pair&,int>> = {<No data fields>},
impl_ = {ptr = 0xf495780}}, end =
{<iterator_facade<boost::signals::detail::named_slot_map_iterator,boost:
:signals::detail::connection_slot_pair,boost::forward_traversal_tag,boos
t::signals::detail::connection_slot_pair&,int>> = {<No data fields>},
impl_ = {ptr = 0xf495790}}, f = {args = 0xbfffe760}, cache = {px =
0x0, pn = {pi_ = 0x0}}}) at ../../../boost/boost/last_value.hpp:43
#17 0x00884a38 in boost::signal2<void, boost::shared_ptr<LyXKeySym>,
key_modifier::state, boost::last_value<void>, int, std::less<int>,
boost::function<void ()(boost::shared_ptr<LyXKeySym>,
key_modifier::state), std::allocator<void> > >::operator()
(this=0xae50974, a1={px = 0xf4857a0, pn = {pi_ = 0x0}}, a2=ctrl)
at ../../../boost/boost/signals/signal_template.hpp:347
#18 0x00347ccc in QContentPane::keyeventTimeout (this=0xae51120) at
QContentPane.C:279
#19 0x004420d4 in QContentPane::qt_invoke (this=0xae51120, _id=47,
_o=0xbfffe9d0) at QContentPane_moc.C:91
#20 0x001d09ac in QObject::activate_signal () at
ControlCommandBuffer.C:137
#21 0x001d0894 in QObject::activate_signal () at
ControlCommandBuffer.C:137
#22 0x002dd2f0 in QTimer::event () at lengthcombo.C:70
#23 0x001b9a08 in QApplication::internalNotify () at GraphicsLoader.C:
172
#24 0x001b9600 in QApplication::notify () at GraphicsLoader.C:172
#25 0x0034e3ec in QEventLoop::macHandleTimer () at
QAskForTextDialog.C:87
#26 0x002224ec in QApplication::globalEventProcessor () at
lcolorcache.C:40
#27 0x931288d4 in DispatchEventToHandlers ()
#28 0x9312802c in SendEventToEventTargetInternal ()
#29 0x93127ea8 in SendEventToEventTargetWithOptions ()
#30 0x9312f1ec in ToolboxEventDispatcherHandler ()
#31 0x93128b24 in DispatchEventToHandlers ()
#32 0x9312802c in SendEventToEventTargetInternal ()
#33 0x9312edb0 in SendEventToEventTarget ()
#34 0x00221c90 in qt_mac_send_event () at lcolorcache.C:40
#35 0x0034f2fc in QEventLoop::processEvents () at QAskForTextDialog.C:87
#36 0x0032c464 in QEventLoop::enterLoop () at lengthcombo.C:70
#37 0x0032c350 in QEventLoop::exec () at lengthcombo.C:70
#38 0x00161e38 in lyx_gui::start ([EMAIL PROTECTED],
[EMAIL PROTECTED]) at lyx_gui.C:253
#39 0x00057d08 in LyX::priv_exec (this=0xae06e60, [EMAIL PROTECTED],
argv=0xbffff830) at lyx_main.C:282
#40 0x0005713c in LyX::exec ([EMAIL PROTECTED], argv=0xbffff830) at
lyx_main.C:143
#41 0x00003268 in main (argc=1, argv=0xbffff830) at main.C:47