Review Request 126512: Use proper deleters for libxcb structs in xembed-sni-proxy.

David Edmundson david at davidedmundson.co.uk
Fri Dec 25 18:06:10 UTC 2015


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

Ship it!


Ship It!

- David Edmundson


On Dec. 25, 2015, 4:53 a.m., Michael Pyne wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/126512/
> -----------------------------------------------------------
> 
> (Updated Dec. 25, 2015, 4:53 a.m.)
> 
> 
> Review request for Plasma.
> 
> 
> Repository: plasma-workspace
> 
> 
> Description
> -------
> 
> Coverity noted we were mismatching new Foo with free(foo), which is
> undefined behavior (CID 1340556). While I was fixing that I noticed we
> have the same issue with QScopedPointer<>: when using QSP to track
> objects returned by libxcb, we must use free() to release memory, not
> C++ delete. (e.g. see
> the [XCB API](http://xcb.freedesktop.org/manual/group__XCB____API.html#ga6727f2bfb24769655e52d1f1c50f58fe)).
> 
> QScopedPointer will do this if we use QScopedPointerPodDeleter.
> 
> 
> Diffs
> -----
> 
>   xembed-sni-proxy/sniproxy.cpp ae6eab7 
> 
> Diff: https://git.reviewboard.kde.org/r/126512/diff/
> 
> 
> Testing
> -------
> 
> I've only compiled and verified no warnings at this point. I didn't see any relevant crash bugs after a quick web search either.
> 
> 
> Thanks,
> 
> Michael Pyne
> 
>

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


More information about the Plasma-devel mailing list