Bug Hunting Session
Bug 99523 - Moving slides (specific actions including UNDO) in the deck crashes Impress
Summary: Moving slides (specific actions including UNDO) in the deck crashes Impress
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
5.1.2.2 release
Hardware: All All
: high major
Assignee: Caolán McNamara
URL:
Whiteboard: target:5.2.0 target:5.1.4
Keywords: haveBacktrace
Depends on:
Blocks:
 
Reported: 2016-04-27 07:01 UTC by Judson Wilson
Modified: 2016-10-25 19:02 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
3-slide deck to reproduce problem (11.79 KB, application/vnd.oasis.opendocument.presentation)
2016-04-30 06:31 UTC, Judson Wilson
Details
bt with symbols (7.50 KB, text/plain)
2016-05-07 22:16 UTC, Julien Nabet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Judson Wilson 2016-04-27 07:01:11 UTC
This may be related to 99522, as I am seeing this after this behavior occurs and I try and undo it.

When trying to move one of the last slides of the deck to the middle of the deck, Impress crashes.

These slides are at the bottom of the deck because of hitting "Ctrl+Shift+End", and afterwards trying to undo.
Comment 1 raal 2016-04-28 11:31:33 UTC
no repro Version: 5.2.0.0.alpha0+; win7
steps:
4 slides
first slide -> Ctrl+Shift+End
undo
no crash
Comment 2 V Stuart Foote 2016-04-29 19:23:39 UTC
On Windows 8.1 Pro 64-bit en-US with
Version: 5.1.2.2 (x64)
Build ID: d3bf12ecb743fc0d20e0be0c58ca359301eb705f
CPU Threads: 8; OS Version: Windows 6.29; UI Render: GL; 
Locale: en-US (en_US)

165 slide .ODP

pick slide 5
<Ctrl>+<Shift>+<End>

moves to end.

<Ctrl>+Z reverts to prior position.

pick slide 6
<Ctrl>+<Shift>+<End>


select and drag it upward 30 slides in the Slides pane--no issue.

<Ctrl>+<Shift>+<Home>

slide positions to top of Slides pane.

Drag it back to its position as slide 6.

No issues.
Comment 3 Judson Wilson 2016-04-30 06:31:54 UTC
Created attachment 124746 [details]
3-slide deck to reproduce problem

Seem to be related to the undo ctrl+shift+z problem. 

To reproduce:

1) put cursor on slide B, after "Bar"
2) ctrl+shift+end (slide moves to end)
3) ctrl+z (nothing happens)
4) drag Slide back to position 2
5) put cursor on slide B, after "Bar"
6) ctrl+shift+end (slide moves to end)
7) ctrl+z (creates new slide at the end, now 2x "B" slides)
8) ctrl+z (moves slide 4 = "B" in place of slide 2 = "C", so now only slides are "A" "B" and "B"
9) move slide 3 to position 2 --> crash!
Comment 4 V Stuart Foote 2016-04-30 14:55:15 UTC
(In reply to Judson Wilson from comment #3)

> To reproduce:
> 
> 1) put cursor on slide B, after "Bar"
> 2) ctrl+shift+end (slide moves to end)
> 3) ctrl+z (nothing happens)
> 4) drag Slide back to position 2
> 5) put cursor on slide B, after "Bar"
> 6) ctrl+shift+end (slide moves to end)
> 7) ctrl+z (creates new slide at the end, now 2x "B" slides)
> 8) ctrl+z (moves slide 4 = "B" in place of slide 2 = "C", so now only slides
> are "A" "B" and "B"
> 9) move slide 3 to position 2 --> crash!

Some uglyness regards actions of the slide sort controls depending on focus in the slide or on the Slide pane sorter, ref bug 98404

However, confirmed crash using STR, on Windows 10 Pro 64-bit en-US with
Version: 5.1.2.2 (x64)
Build ID: d3bf12ecb743fc0d20e0be0c58ca359301eb705f
CPU Threads: 8; OS Version: Windows 6.19; UI Render: GL; 
Locale: en-US (en_US)

Stacktrace of crash...

0:021> g
(1d0c.fcc): Access violation - code c0000005 (first chance)
First chance exceptions are reported before any exception handling.
This exception may be expected and handled.
sdlo!SdPage::GetName+0xe9:
00007ff9`bfa2fd09 488b10          mov     rdx,qword ptr [rax] ds:00000000`00000000=????????????????
0:000> ~* kp

.  0  Id: 1d0c.fcc Suspend: 1 Teb: 00000006`fb917000 Unfrozen
Child-SP          RetAddr           Call Site
00000006`fc38f000 00007ff9`bfd3d1ed sdlo!SdPage::GetName(void)+0xe9 [c:\cygwin64\home\buildslave\source\libo-core\sd\source\core\sdpage.cxx @ 2546]
00000006`fc38f070 00007ff9`bfd361e3 sdlo!sd::DrawViewShell::ResetActualPage(void)+0x10d [c:\cygwin64\home\buildslave\source\libo-core\sd\source\ui\view\drviews1.cxx @ 682]
00000006`fc38f0f0 00007ff9`c1388ff8 sdlo!sd::DrawView::Notify(class SfxBroadcaster * rBC = 0x00000000`0000001b, class SfxHint * rHint = 0x00000000`00000007)+0x83 [c:\cygwin64\home\buildslave\source\libo-core\sd\source\ui\view\drawview.cxx @ 381]
00000006`fc38f130 00007ff9`c18e6f9a mergedlo!SfxBroadcaster::Broadcast(class SfxHint * rHint = 0x000001f2`384fc960)+0x58 [c:\cygwin64\home\buildslave\source\libo-core\svl\source\notify\sfxbroadcaster.cxx @ 46]
00000006`fc38f160 00007ff9`bfa11abc mergedlo!SdrModel::RemovePage(unsigned short nPgNum = 0xc960)+0xca [c:\cygwin64\home\buildslave\source\libo-core\svx\source\svdraw\svdmodel.cxx @ 1468]
00000006`fc38f1d0 00007ff9`bfcc3e51 sdlo!SdDrawDocument::RemovePage(unsigned short nPgNum = 7)+0x2c [c:\cygwin64\home\buildslave\source\libo-core\sd\source\core\drawdoc2.cxx @ 392]
00000006`fc38f210 00007ff9`bfc47d44 sdlo!SdDrawPagesAccess::remove(class com::sun::star::uno::Reference<com::sun::star::drawing::XDrawPage> * xPage = 0x000001f2`38d620f0)+0x161 [c:\cygwin64\home\buildslave\source\libo-core\sd\source\ui\unoidl\unomodel.cxx @ 2905]
00000006`fc38f290 00007ff9`bfc48089 sdlo!sd::slidesorter::controller::SelectionManager::DeleteSelectedNormalPages(class std::vector<SdPage *,std::allocator<SdPage *> > * rSelectedPages = 0x000001f2`4f72a5c0)+0x174 [c:\cygwin64\home\buildslave\source\libo-core\sd\source\ui\slidesorter\controller\slsselectionmanager.cxx @ 170]
00000006`fc38f2f0 00007ff9`bfc36f3e sdlo!sd::slidesorter::controller::SelectionManager::DeleteSelectedPages(bool bSelectFollowingPage = true)+0x2e9 [c:\cygwin64\home\buildslave\source\libo-core\sd\source\ui\slidesorter\controller\slsselectionmanager.cxx @ 125]
00000006`fc38f3e0 00007ff9`c1fea0bb sdlo!sd::slidesorter::controller::Clipboard::ProcessDragFinished(void * pUserData = 0x000001f2`4f323240)+0xae [c:\cygwin64\home\buildslave\source\libo-core\sd\source\ui\slidesorter\controller\slsclipboard.cxx @ 606]
00000006`fc38f430 00007ff9`c2333b64 mergedlo!ImplWindowFrameProc(class vcl::Window * _pWindow = 0x00000000`002803c4, class SalFrame * __formal = 0x00000000`002803c4, unsigned short nEvent = 0x3240, void * pEvent = 0x00000000`00000000)+0x49b [c:\cygwin64\home\buildslave\source\libo-core\vcl\source\window\winproc.cxx @ 2574]
00000006`fc38f540 00007ff9`c23341b0 mergedlo!SalFrameWndProc(struct HWND__ * hWnd = 0x00000000`00000000, unsigned int nMsg = 0x40, unsigned int64 wParam = 0x00007ff9`c2334160, int64 lParam = 0n2140222403136, int * rDef = 0x00000006`fc38f610)+0x864 [c:\cygwin64\home\buildslave\source\libo-core\vcl\win\source\window\salframe.cxx @ 5773]
00000006`fc38f5e0 00007ff9`ef771169 mergedlo!SalFrameWndProcW(struct HWND__ * hWnd = 0x00000000`002803c4, unsigned int nMsg = 0x482, unsigned int64 wParam = 0, int64 lParam = 0n2140222403136)+0x50 [c:\cygwin64\home\buildslave\source\libo-core\vcl\win\source\window\salframe.cxx @ 5932]
00000006`fc38f650 00007ff9`ef770aba USER32!UserCallWinProcCheckWow+0x1f9
00000006`fc38f740 00007ff9`c800b7fe USER32!CallWindowProcW+0x10a
00000006`fc38f790 00007ff9`ef771169 OPENGL32!wglWndProc+0x4fe
00000006`fc38f810 00007ff9`ef770c97 USER32!UserCallWinProcCheckWow+0x1f9
00000006`fc38f900 00007ff9`c22f41d5 USER32!DispatchMessageWorker+0x1a7
00000006`fc38f980 00007ff9`c22f3f71 mergedlo!ImplSalYield(bool bWait = true, bool bHandleAllCurrentEvents = false)+0x85 [c:\cygwin64\home\buildslave\source\libo-core\vcl\win\source\app\salinst.cxx @ 636]
00000006`fc38f9f0 00007ff9`c226bc0b mergedlo!WinSalInstance::DoYield(bool bWait = false, bool bHandleAllCurrentEvents = false, unsigned int64 nReleased = 0)+0xf1 [c:\cygwin64\home\buildslave\source\libo-core\vcl\win\source\app\salinst.cxx @ 699]
00000006`fc38fa40 00007ff9`c226a3dc mergedlo!ImplYield(bool i_bWait = false, bool i_bAllEvents = true, unsigned int64 nReleased = 0x000001f2`383cb5f0)+0x7b [c:\cygwin64\home\buildslave\source\libo-core\vcl\source\app\svapp.cxx @ 509]
00000006`fc38faa0 00007ff9`c12b5c82 mergedlo!Application::Execute(void)+0x14c [c:\cygwin64\home\buildslave\source\libo-core\vcl\source\app\svapp.cxx @ 470]
00000006`fc38faf0 00007ff9`c2272089 mergedlo!desktop::Desktop::Main(void)+0x1082 [c:\cygwin64\home\buildslave\source\libo-core\desktop\source\app\app.cxx @ 1609]
00000006`fc38fdb0 00007ff9`c2272422 mergedlo!ImplSVMain(void)+0x49 [c:\cygwin64\home\buildslave\source\libo-core\vcl\source\app\svmain.cxx @ 170]
00000006`fc38fdf0 00007ff9`c12d0fa5 mergedlo!SVMain(void)+0x32 [c:\cygwin64\home\buildslave\source\libo-core\vcl\source\app\svmain.cxx @ 208]
00000006`fc38fe20 00007ff6`2c94102e mergedlo!soffice_main(void)+0x75 [c:\cygwin64\home\buildslave\source\libo-core\desktop\source\app\sofficemain.cxx @ 96]
00000006`fc38fed0 00007ff6`2c94139d soffice+0x102e
00000006`fc38ff00 00007ff9`ef558102 soffice!main+0x35d
00000006`fc38ff40 00007ff9`eff0c5b4 KERNEL32!BaseThreadInitThunk+0x22
00000006`fc38ff70 00000000`00000000 ntdll!RtlUserThreadStart+0x34
Comment 5 Julien Nabet 2016-05-07 22:16:18 UTC
Created attachment 124901 [details]
bt with symbols

On pc Debian x86-64 with master sources updated today, I could reproduce this.
Comment 6 Commit Notification 2016-05-13 15:16:07 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=130f8eef234c6f44798d597814a0debc202fe8cc

Related: tdf#99523 two undo actions listed after dragging a slide

It will be available in 5.2.0.

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.
Comment 7 Caolán McNamara 2016-05-13 15:21:04 UTC
My commit doesn't fix this (yet). We seem to not record an undo if ctrl+shift+end is called when the text box is active so it might all boil down to 98404
Comment 8 Commit Notification 2016-05-16 16:20:11 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=4e41e784b97a5b6f5e0cc1f5b24b816ef887b310

Resolves: tdf#99523 exit text edit and unmark objects before moving slide

It will be available in 5.2.0.

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.
Comment 9 Commit Notification 2016-05-18 11:55:39 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=bb3671180eb7327be9ac178e0d8341322f63d72a

Related: tdf#99523 NotifyPageEvent ultimately comes from HINT_PAGEORDERCHG...

It will be available in 5.2.0.

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.
Comment 10 Commit Notification 2016-05-18 11:55:44 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=db00223e6d3132eac9603e5dabd20cd03f599cb3

Related: tdf#99523 select only the desired slides

It will be available in 5.2.0.

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.
Comment 11 Caolán McNamara 2016-05-18 13:10:58 UTC
https://gerrit.libreoffice.org/#/c/25107/ for combined fix for a multiple set of problems which when resolved makes this do what it should do
Comment 12 Commit Notification 2016-05-23 08:38:52 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-5-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=83c3c4d46d7185856041be3d9da660aaceff8799&h=libreoffice-5-1

Resolves: tdf#99523 exit text edit and unmark objects before moving slide

It will be available in 5.1.4.

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.