Fix resource leak
CID 178811 (#1 of 1): Resource leak (RESOURCE_LEAK) 25. leaked_storage: Variable dptr going out of scope leaks the storage it points to. Change-Id: I3354fe46cfb08701f387f65aaaa5c4f235079501 Coverity-Id: 178811 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
This commit is contained in:
parent
5dbd040d1c
commit
0803285fe7
@ -1549,6 +1549,7 @@ QPixmap QX11PlatformPixmap::transformed(const QTransform &transform, Qt::Transfo
|
|||||||
if (!qt_xForm_helper(mat, xi->xoffset, type, bpp, dptr, xbpl, p_inc, h, sptr, sbpl, ws, hs)){
|
if (!qt_xForm_helper(mat, xi->xoffset, type, bpp, dptr, xbpl, p_inc, h, sptr, sbpl, ws, hs)){
|
||||||
qWarning("QPixmap::transform: display not supported (bpp=%d)",bpp);
|
qWarning("QPixmap::transform: display not supported (bpp=%d)",bpp);
|
||||||
QPixmap pm;
|
QPixmap pm;
|
||||||
|
free(dptr);
|
||||||
return pm;
|
return pm;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user