summaryrefslogtreecommitdiffstats
path: root/libvncserver/corre.c
diff options
context:
space:
mode:
Diffstat (limited to 'libvncserver/corre.c')
-rwxr-xr-xlibvncserver/corre.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/libvncserver/corre.c b/libvncserver/corre.c
index c1164c0..75f1211 100755
--- a/libvncserver/corre.c
+++ b/libvncserver/corre.c
@@ -41,7 +41,7 @@ static char *rreBeforeBuf = NULL;
static int rreAfterBufSize = 0;
static char *rreAfterBuf = NULL;
-static int rreAfterBufLen;
+static int rreAfterBufLen = 0;
static int subrectEncode8(uint8_t *data, int w, int h);
static int subrectEncode16(uint16_t *data, int w, int h);
@@ -145,9 +145,9 @@ rfbSendSmallRectEncodingCoRRE(rfbClientPtr cl,
return rfbSendRectEncodingRaw(cl, x, y, w, h);
}
- cl->rectanglesSent[rfbEncodingCoRRE]++;
- cl->bytesSent[rfbEncodingCoRRE] += (sz_rfbFramebufferUpdateRectHeader
- + sz_rfbRREHeader + rreAfterBufLen);
+ rfbStatRecordEncodingSent(cl,rfbEncodingCoRRE,
+ sz_rfbFramebufferUpdateRectHeader + sz_rfbRREHeader + rreAfterBufLen,
+ sz_rfbFramebufferUpdateRectHeader + w * h * (cl->format.bitsPerPixel / 8));
if (cl->ublen + sz_rfbFramebufferUpdateRectHeader + sz_rfbRREHeader
> UPDATE_BUF_SIZE)