summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordscho <dscho>2004-01-30 09:59:32 +0000
committerdscho <dscho>2004-01-30 09:59:32 +0000
commit2fbf23c17ffbc03c5a4d4aa1bda55586e8f41a8e (patch)
tree5f13745ef9a48a7f165a99675a940e1cfec03c65
parente0cbabec292fbc8058d98c93fcc8d3cf5b8f5d69 (diff)
downloadlibtdevnc-2fbf23c17ffbc03c5a4d4aa1bda55586e8f41a8e.tar.gz
libtdevnc-2fbf23c17ffbc03c5a4d4aa1bda55586e8f41a8e.zip
memory leaks fixed
-rw-r--r--ChangeLog4
-rw-r--r--rfbserver.c8
2 files changed, 12 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 72a10b5..248eaa6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2004-01-30 Johannes E. Schindelin <Johannes.Schindelin@gmx.de>
+ * Thanks to Paul Fox from Bright Star Engineering,
+ a few more memory leaks were fixed.
+
2004-01-29 Johannes E. Schindelin <Johannes.Schindelin@gmx.de>
* Honour the check for libz and libjpeg again.
diff --git a/rfbserver.c b/rfbserver.c
index 1b11e6b..7a40a7b 100644
--- a/rfbserver.c
+++ b/rfbserver.c
@@ -1213,6 +1213,7 @@ rfbSendFramebufferUpdate(cl, givenUpdateRegion)
int h = rect.y2 - y;
nUpdateRegionRects += (((h-1) / (ZLIB_MAX_SIZE( w ) / w)) + 1);
}
+ sraRgnReleaseIterator(i);
#ifdef LIBVNCSERVER_HAVE_LIBJPEG
} else if (cl->preferredEncoding == rfbEncodingTight) {
nUpdateRegionRects = 0;
@@ -1296,24 +1297,28 @@ rfbSendFramebufferUpdate(cl, givenUpdateRegion)
case rfbEncodingRaw:
if (!rfbSendRectEncodingRaw(cl, x, y, w, h)) {
sraRgnDestroy(updateRegion);
+ sraRgnReleaseIterator(i);
return FALSE;
}
break;
case rfbEncodingRRE:
if (!rfbSendRectEncodingRRE(cl, x, y, w, h)) {
sraRgnDestroy(updateRegion);
+ sraRgnReleaseIterator(i);
return FALSE;
}
break;
case rfbEncodingCoRRE:
if (!rfbSendRectEncodingCoRRE(cl, x, y, w, h)) {
sraRgnDestroy(updateRegion);
+ sraRgnReleaseIterator(i);
return FALSE;
}
break;
case rfbEncodingHextile:
if (!rfbSendRectEncodingHextile(cl, x, y, w, h)) {
sraRgnDestroy(updateRegion);
+ sraRgnReleaseIterator(i);
return FALSE;
}
break;
@@ -1321,6 +1326,7 @@ rfbSendFramebufferUpdate(cl, givenUpdateRegion)
case rfbEncodingZlib:
if (!rfbSendRectEncodingZlib(cl, x, y, w, h)) {
sraRgnDestroy(updateRegion);
+ sraRgnReleaseIterator(i);
return FALSE;
}
break;
@@ -1328,6 +1334,7 @@ rfbSendFramebufferUpdate(cl, givenUpdateRegion)
case rfbEncodingTight:
if (!rfbSendRectEncodingTight(cl, x, y, w, h)) {
sraRgnDestroy(updateRegion);
+ sraRgnReleaseIterator(i);
return FALSE;
}
break;
@@ -1337,6 +1344,7 @@ rfbSendFramebufferUpdate(cl, givenUpdateRegion)
case rfbEncodingZRLE:
if (!rfbSendRectEncodingZRLE(cl, x, y, w, h)) {
sraRgnDestroy(updateRegion);
+ sraRgnReleaseIterator(i);
return FALSE;
}
break;