Problem description: When one copies a block from Calc into Writer and there is a cell with a comment, LibreOffice crashes. Steps to reproduce: 1. Make a spreadsheet in Calc 2. add a comment to a cell 3. copy block of cells, including commented cell 4. paste in Writer Current behavior: LibreOffice crashes Expected behavior: Block of cells would paste into Writer [preferably] with or without the comment, without crashing LibreOffice. Operating System: Ubuntu Version: 4.2.3.3 release
reproducibile with 4.2.3.3 under Win7x64 not reproducibile with 4.1.5.3 hence regression
Created attachment 98194 [details] console logs + bt with symbols On pc Debian x86-64 with master sources updated today (1e5b495a882493a81cc82ee34e3339b071bc162d), I could reproduce the crash.
Created attachment 98196 [details] proposed patch Here's a simple patch which prevents the crash. But comment isn't taken into account.
Kohei/Michael: I attached a bt + a straightforward patch (but which doesn't take into account the comment). Any idea?
No idea. I'll look.
Julien's patch may prevent a crash, but it won't address the fundamental question of why the note caption failed to get created there. Plus notes won't get copied, which is not good.
So, the crash is an unfortunate side effect of how the drawing layer behaves with regard to clipboard documents. I can think of a few different ways to fix this... Let's see.
Kohei: of course it was just a band-aid fix to avoid the crash (see https://bugs.freedesktop.org/show_bug.cgi?id=78054#c3) waiting for the real fix :-)
This is not a Writer bug.
Kohei Yoshida committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=fe451fb94a33c914c0a7c1265c013d9704af850a fdo#78054: Initialize drawing layer when the document contains notes. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
4.2 backport: https://gerrit.libreoffice.org/9254
Kohei Yoshida committed a patch related to this issue. It has been pushed to "libreoffice-4-2": http://cgit.freedesktop.org/libreoffice/core/commit/?id=b26b9606efa30c0a44e20dcf638fbd1e27f05089&h=libreoffice-4-2 fdo#78054: Initialize drawing layer when the document contains notes. It will be available in LibreOffice 4.2.5. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Fixed.
I forgot to assign it to me.