From ccdbe8f3256c3c776a1cc1a0517a38437b9e2c65 Mon Sep 17 00:00:00 2001 From: steven_carr Date: Mon, 15 May 2006 05:37:39 +0000 Subject: The great UltraVNC Compatibility Commit --- libvncserver/scale.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'libvncserver/scale.c') diff --git a/libvncserver/scale.c b/libvncserver/scale.c index 63d232e..67de35f 100644 --- a/libvncserver/scale.c +++ b/libvncserver/scale.c @@ -128,8 +128,8 @@ void rfbScaledCorrection(rfbScreenInfoPtr from, rfbScreenInfoPtr to, int *x, int *h = (int)h2; /* Small changes for a thumbnail may be scaled to zero */ - if (*w==0) *w++; - if (*h==0) *h++; + if (*w==0) (*w)++; + if (*h==0) (*h)++; /* scaling from small to big may overstep the size a bit */ if (*x+*w > to->width) *w=to->width - *x; if (*y+*h > to->height) *h=to->height - *y; @@ -212,7 +212,9 @@ void rfbScaledScreenUpdateRect(rfbScreenInfoPtr screen, rfbScreenInfoPtr ptr, in pixel_value += (srcptr2[z] << (8 * z)); break; } - //srcptr2 += bytesPerPixel; + /* + srcptr2 += bytesPerPixel; + */ red += ((pixel_value >> redShift) & redMax); green += ((pixel_value >> greenShift) & greenMax); -- cgit v1.2.1