Bug 360172 - Crash on export
Summary: Crash on export
Status: RESOLVED FIXED
Alias: None
Product: umbrello
Classification: Applications
Component: general (show other bugs)
Version: 2.18.2 (KDE Applications 15.12.2)
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Umbrello Development Group
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-03-06 20:49 UTC by Kip
Modified: 2016-03-07 09:12 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 2.18.3 (KDE Applications 15.12.3)
Sentry Crash Report:


Attachments
UML project file which seems to trip the breakpoint. (135.56 KB, application/gzip)
2016-03-06 20:50 UTC, Kip
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kip 2016-03-06 20:49:17 UTC
I am experiencing a crash on export of my XMI file. It appears as though a breakpoint trap is being tripped for an inotify read(): Bad file descriptor.

Reproducible: Always

Steps to Reproduce:
umbrello --export svg Engine.xmi


Actual Results:  
KCrash: Application 'umbrello' crashing...
KCrash: Attempting to start /usr/lib/kde4/libexec/drkonqi from kdeinit
KCrash: Connect sock_file=/home/kip/.kde/socket-kip-desktop/kdeinit4__0

(umbrello:27106): GLib-GIO-ERROR **: inotify read(): Bad file descriptor
Trace/breakpoint trap (core dumped)


See the attached compressed XMI project file.
Comment 1 Kip 2016-03-06 20:50:07 UTC
Created attachment 97722 [details]
UML project file which seems to trip the breakpoint.
Comment 2 Ralf Habacker 2016-03-07 08:43:19 UTC
Can reproduce the crash also in stable branch. It happens in UMLApp() destructor, while accessing already destroyed undo stack.
Comment 3 Kip 2016-03-07 08:50:23 UTC
Thanks Ralf, and nice to see you again. Hopefully this one isn't too hard to patch.
Comment 4 Ralf Habacker 2016-03-07 08:55:07 UTC
Git commit 79f0530e4c26fd75b651db5c3747656969987c2a by Ralf Habacker.
Committed on 07/03/2016 at 08:54.
Pushed by habacker into branch 'Applications/15.12'.

Fix 'Crash on export'.

On destructing class UMLApp an already destroyed undo stack is
referenced. The fix is to guard access to undo stack with
m_pUndoStack != 0.
FIXED-IN:2.18.3 (KDE Applications 2.18.3)

M  +20   -2    umbrello/uml.cpp

http://commits.kde.org/umbrello/79f0530e4c26fd75b651db5c3747656969987c2a
Comment 5 Ralf Habacker 2016-03-07 09:03:59 UTC
(In reply to Kip from comment #3)
> Thanks Ralf, and nice to see you again. 
Me too :-) 
>Hopefully this one isn't too hard to  patch.
see comment 5
BTW: The Engine.xmi file you provided has been used as first class test case for several bugs and feature requests :-)
Comment 6 Ralf Habacker 2016-03-07 09:04:28 UTC
(In reply to Ralf Habacker from comment #5)
> see comment 5
comment 4
Comment 7 Kip 2016-03-07 09:12:36 UTC
I confirm git head fixes the crash. =)

As for Engine.xmi, that's hilarious and glad to know my engine is so poorly designed it is used to break other software. ;)

Here's a link to the upstream location where I keep it in Bzr:
https://bazaar.launchpad.net/~avaneya/avaneya/trunk/view/head:/Documentation/Contributors/AresEngine/UML/Engine.xmi