This isn't the most helpful bug report, since I can't reliably reproduce it. But here's a recipe that *sometimes* works. (I have a document in which it reliably works, but it's fairly long, and I can't seem to find a way to cut it down to a minimal example: any cutting I do eliminates the crash. Let me know if anyone wants to see the document.)

Start with an empty document in book class. In a standard paragraph, insert a note. In the body of the note, type some text, and make it be a chapter heading (while leaving the paragraph in which the note is embedded a standard paragraph). Then change the document class to article. LyX-136 (sometimes) crashes.

It only happens, so long as I can tell, when the note with the chapter heading in it is the first paragraph of the document.

Here's the output from gdb:


Program received signal EXC_BAD_ACCESS, Could not access memory.
0x00064690 in ParIterator::operator++ (this=0xbfffe91c) at iterators.C:28 28 Paragraph * par = p.it.getInset()->getFirstParagraph(0);
(gdb) bt
#0 0x00064690 in ParIterator::operator++ (this=0xbfffe91c) at iterators.C:28 #1 0x0001175c in CutAndPaste::SwitchLayoutsBetweenClasses (c1=13, c2=3, par=0x9663ad0) at CutAndPaste.C:459 #2 0x00291b18 in ControlDocument::classApply (this=0x60576ec) at ControlDocument.C:120 #3 0x0029171c in ControlDocument::apply (this=0x60576ec) at ControlDocument.C:72 #4 0x001b4d44 in ControlButtons::OKButton (this=0x60576ec) at ControlButtons.C:35
#5  0x00430bb8 in Qt2Base::slotOK (this=0x6057784) at Qt2Base.C:101
#6 0x0042ff2c in Qt2Base::qt_invoke () at /usr/include/gcc/darwin/2.95.2/g++/stl_pair.h:50
#7  0x0022a324 in QObject::activate_signal ()
#8  0x0022a1e8 in QObject::activate_signal ()
#9  0x003154d8 in QButton::clicked ()
#10 0x00475d78 in QButton::mouseReleaseEvent () at /usr/include/gcc/darwin/2.95.2/g++/stl_pair.h:50
#11 0x00239dac in QWidget::event ()
#12 0x00230ce4 in QApplication::internalNotify ()
#13 0x00230364 in QApplication::notify ()
#14 0x0026741c in QApplication::globalEventProcessor () at ../../../boost/boost/shared_ptr.hpp:265
#15 0x92881fa0 in DispatchEventToHandlers ()
#16 0x92882214 in SendEventToEventTargetInternal ()
#17 0x928946bc in SendEventToEventTarget ()
#18 0x0023cd40 in qt_window_event ()
#19 0x92881fa0 in DispatchEventToHandlers ()
#20 0x92882214 in SendEventToEventTargetInternal ()
#21 0x928946bc in SendEventToEventTarget ()
#22 0x928a2d3c in HandleMouseEventForWindow(OpaqueWindowPtr*, OpaqueEventRef*, unsigned short) ()
#23 0x929c3524 in HandleMouseEvent(OpaqueEventRef*) ()
#24 0x92892c5c in ToolboxEventDispatcherHandler(OpaqueEventHandlerCallRef*, OpaqueEventRef*, void*) ()
#25 0x9288205c in DispatchEventToHandlers ()
#26 0x92882214 in SendEventToEventTargetInternal ()
#27 0x928946bc in SendEventToEventTarget ()
#28 0x00265780 in qt_mac_send_event () at ../../../boost/boost/shared_ptr.hpp:265
#29 0x003e7c54 in QEventLoop::processEvents ()
#30 0x00409858 in QEventLoop::enterLoop ()
#31 0x0040974c in QEventLoop::exec ()
#32 0x00230e54 in QApplication::exec ()
#33 0x00197144 in lyx_gui::start ([EMAIL PROTECTED], [EMAIL PROTECTED]) at lyx_gui.C:218 #34 0x0006f21c in LyX::LyX (this=0xbffffafc, [EMAIL PROTECTED], argv=0xbffffbcc) at lyx_main.C:194
#35 0x000a3c38 in main (argc=1, argv=0xbffffbcc) at ../src/main.C:31

Bennett

Reply via email to