From 0803285fe7e6bca32eac77e88a2cb1f47a308865 Mon Sep 17 00:00:00 2001 From: Jesus Fernandez Date: Thu, 27 Apr 2017 18:00:46 +0200 Subject: 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 --- src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp b/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp index 6f970f6d6d..08752da648 100644 --- a/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp +++ b/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp @@ -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)){ qWarning("QPixmap::transform: display not supported (bpp=%d)",bpp); QPixmap pm; + free(dptr); return pm; } -- cgit v1.2.3