[Marble-devel] Review Request 119069: Marble (routing): fix crash when entering guidance mode

Dennis Nienhüser earthwings at gentoo.org
Tue Jul 1 21:36:22 UTC 2014


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/119069/#review61432
-----------------------------------------------------------

Ship it!


Ship It!

- Dennis Nienhüser


On July 1, 2014, 4:33 p.m., Jonathan Marten wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/119069/
> -----------------------------------------------------------
> 
> (Updated July 1, 2014, 4:33 p.m.)
> 
> 
> Review request for Marble.
> 
> 
> Bugs: 336771
>     http://bugs.kde.org/show_bug.cgi?id=336771
> 
> 
> Repository: marble
> 
> 
> Description
> -------
> 
> The reference bug describes a crash when displaying the "Caution: Driving instructions may be..." message box when guidance is started.
> 
> The problem is that a QCheckBox is created on the stack and added to the message box, which adopts it as a child.  This is dangerous according to the QObject::~QObject documentation:
> 
>   Warning: All child objects are deleted. If any of these objects are on the stack or global, sooner or later your program will crash.
> 
> This change creates the check box on the heap instead;  as a child of the message box, it will be deleted when the message box is deleted.
> 
> 
> Diffs
> -----
> 
>   src/lib/marble/routing/RoutingManager.cpp ac49db7 
> 
> Diff: https://git.reviewboard.kde.org/r/119069/diff/
> 
> 
> Testing
> -------
> 
> Built Marble with this change, ran crashing test case as in bug report - no crash.
> 
> 
> Thanks,
> 
> Jonathan Marten
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/marble-devel/attachments/20140701/9fa775d8/attachment.html>


More information about the Marble-devel mailing list