Review Request: A new autoptr class for QPointer.

Thomas McGuire mcguire at kde.org
Thu Jul 9 12:15:38 BST 2009


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.kde.org/r/955/#review1511
-----------------------------------------------------------


Seems fine to me, this would be something really useful, especially because we have to wait for QScopedPointer until at least 4.6.

So I think this should be included in kdelibs.

- Thomas


On 2009-07-08 10:12:46, David Jarvie wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.kde.org/r/955/
> -----------------------------------------------------------
> 
> (Updated 2009-07-08 10:12:46)
> 
> 
> Review request for kdelibs.
> 
> 
> Summary
> -------
> 
> This template class is inherited from QPointer, and provides the additional feature that on destruction it deletes the QObject whose pointer it contains.
> 
> The motivation for adding this class is to deal with the issue described in  http://www.kdedevelopers.org/node/3919, whereby if a modal dialog is open when an application is told to quit, the dialog will be deleted by its parent, usually resulting in a crash due to double deletion of the dialog, or due to accessing the dangling pointer to the dialog.
> 
> This class is required by several applications in kdepim, and other modules would also benefit by using it.
> 
> A unit test will be provided if the class is approved.
> 
> 
> Diffs
> -----
> 
>   /trunk/KDE/kdelibs/kdecore/util/kautopointer.h PRE-CREATION 
> 
> Diff: http://reviewboard.kde.org/r/955/diff
> 
> 
> Testing
> -------
> 
> Works successfully in KAlarm.
> 
> 
> Thanks,
> 
> David
> 
>





More information about the kde-core-devel mailing list