Crash on master because of cursor position in session

Scott Kostyshak skostysh at lyx.org
Sun Jan 23 19:16:32 UTC 2022


On Sun, Jan 23, 2022 at 08:03:32PM +0100, Jean-Marc Lasgouttes wrote:
> Le 22/01/2022 à 23:04, Pavel Sanda a écrit :
> > On Sat, Jan 22, 2022 at 09:43:15PM +0100, Pavel Sanda wrote:
> > > lyx::TextMetrics::redoParagraph:522 pm.rows() = breakParagraph(bigrow); -> step into
> > > lyx::TextMetrics::breakParagraph:1136 tail = rb.shortenIfNeeded(width, next_width); -> step into
> > > lyx::Row::shortenIfNeeded:640 if (cit->splitAt(w - wid, next_width, true, tail)) {
> > > 
> > > ... (equivalently 4x cont on  Row.cpp:640 breakpoint and then step in)
> > > 
> > > Thread 1 "lyx" hit Breakpoint 5, lyx::Row::shortenIfNeeded (this=0x5555588a7ae0, w=569, next_width=203) at Row.cpp:640
> > > 640             if (cit->splitAt(w - wid, next_width, true, tail)) {
> > 
> > 
> > Biset leads to:
> > commit d723b90344c0e56b26fc69aa00cb3001e074a723
> > Author: Jean-Marc Lasgouttes <lasgouttes at lyx.org>
> > Date:   Mon Sep 6 14:52:42 2021 +0200
> > 
> >      Break multi-row strings in one pass
> 
> Thanks to all for the debugging while I was not available. It should be
> fixed now.
> 
> To find the right point, I discovered that gdb has a command "catch throw"
> that stops when there is an exception. Using this, I saw that it was code
> trying to handle a negative string length. From there, it was not too
> difficult to find the culprit.

Nice trick to know.

> Please test. The other zoom issue is still pending, of course.

Thanks for the fix. Just tested and I can no longer reproduce.

Scott
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.lyx.org/pipermail/lyx-devel/attachments/20220123/33572b96/attachment.asc>


More information about the lyx-devel mailing list