From: Marc-André Moreau Date: Wed, 25 Jun 2014 22:00:48 +0000 (-0400) Subject: xfreerdp: fix egfx SurfaceToSurface off-by-one X-Git-Tag: 1.2.0-beta1+android9~18^2~53 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c20c3abdf1defbe3cfb3a66d1a84bd6e3f096cdf;p=platform%2Fupstream%2Ffreerdp.git xfreerdp: fix egfx SurfaceToSurface off-by-one --- diff --git a/client/X11/xf_gfx.c b/client/X11/xf_gfx.c index fec5036..b14e2c7 100644 --- a/client/X11/xf_gfx.c +++ b/client/X11/xf_gfx.c @@ -27,9 +27,6 @@ int xf_ResetGraphics(RdpgfxClientContext* context, RDPGFX_RESET_GRAPHICS_PDU* re { xfContext* xfc = (xfContext*) context->custom; - printf("xf_ResetGraphics: width: %d height: %d\n", - resetGraphics->width, resetGraphics->height); - if (xfc->rfx) { rfx_context_free(xfc->rfx); @@ -376,9 +373,6 @@ int xf_CreateSurface(RdpgfxClientContext* context, RDPGFX_CREATE_SURFACE_PDU* cr xfGfxSurface* surface; xfContext* xfc = (xfContext*) context->custom; - printf("xf_CreateSurface: surfaceId: %d width: %d height: %d format: 0x%02X\n", - createSurface->surfaceId, createSurface->width, createSurface->height, createSurface->pixelFormat); - surface = (xfGfxSurface*) calloc(1, sizeof(xfGfxSurface)); if (!surface) @@ -409,8 +403,6 @@ int xf_DeleteSurface(RdpgfxClientContext* context, RDPGFX_DELETE_SURFACE_PDU* de surface = (xfGfxSurface*) context->GetSurfaceData(context, deleteSurface->surfaceId); - printf("xf_DeleteSurface: surfaceId: %d\n", deleteSurface->surfaceId); - if (surface) { XFree(surface->image); @@ -496,8 +488,8 @@ int xf_SurfaceToSurface(RdpgfxClientContext* context, RDPGFX_SURFACE_TO_SURFACE_ if (!surfaceSrc || !surfaceDst) return -1; - nWidth = rectSrc->right - rectSrc->left + 1; - nHeight = rectSrc->bottom - rectSrc->top + 1; + nWidth = rectSrc->right - rectSrc->left; + nHeight = rectSrc->bottom - rectSrc->top; for (index = 0; index < surfaceToSurface->destPtsCount; index++) {