Review Request 109339: Delete the old konsoleWidget when loading a new project.

Giorgos Tsiapaliokas terietor at gmail.com
Mon Mar 11 09:32:04 UTC 2013


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



plasmate/mainwindow.cpp
<http://git.reviewboard.kde.org/r/109339/#comment21646>

    it should be
    
    delete m_konsoleWidget;
    m_konsoleWidget = 0;
    
    after the delete the pointer is dangling,
    of course since createKonsoleFor returns
    either 0 or a valid pointer, we don't have an issue, *but* if in the future the code changes we might have a dangling pointer and this isn't good :)
    
    
    


- Giorgos Tsiapaliokas


On March 7, 2013, 2:10 p.m., Tianyu Zhu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/109339/
> -----------------------------------------------------------
> 
> (Updated March 7, 2013, 2:10 p.m.)
> 
> 
> Review request for Plasma.
> 
> 
> Description
> -------
> 
> If the old konsoleWidget is not deleted when loading a new project, it shows up along with a new one in the project view.
> This also fixes a memory leak.
> 
> 
> This addresses bug https://bugs.kde.org/show_bug.cgi?id=316276.
>     http://bugs.kde.org/show_bug.cgi?id=https://bugs.kde.org/show_bug.cgi?id=316276
> 
> 
> Diffs
> -----
> 
>   plasmate/mainwindow.cpp 13234ec 
> 
> Diff: http://git.reviewboard.kde.org/r/109339/diff/
> 
> 
> Testing
> -------
> 
> It works on my machine: Thinkpad T520, Kubuntu 12.10, KDE 4.10.1
> 
> 
> Thanks,
> 
> Tianyu Zhu
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20130311/c6a51c93/attachment.html>


More information about the Plasma-devel mailing list