aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Sibiller <uli42@gmx.de>2019-06-21 15:17:04 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2019-09-29 17:10:05 +0200
commit59f1d37376d20d855d93fae4919bf81995c24281 (patch)
tree252de20b59d387d9748a77dfa13c4e4338058077
parent157c8c7f37a9d7f613d273e32aac40f8a7df1d36 (diff)
downloadnx-libs-59f1d37376d20d855d93fae4919bf81995c24281.tar.gz
nx-libs-59f1d37376d20d855d93fae4919bf81995c24281.tar.bz2
nx-libs-59f1d37376d20d855d93fae4919bf81995c24281.zip
NXrender.c: fix possible memory leak
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/NXrender.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c
index 7456bd3a5..8a288b485 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c
@@ -715,6 +715,9 @@ ProcRenderTrapezoids (ClientPtr client)
{
if (pFormat != NULL)
{
+ if (nxagentTrapezoidExtents && nxagentTrapezoidExtents != NullBox)
+ free(nxagentTrapezoidExtents);
+
nxagentTrapezoidExtents = (BoxPtr) malloc(sizeof(BoxRec));
miTrapezoidBounds (ntraps, (xTrapezoid *) &stuff[1], nxagentTrapezoidExtents);