buildroot/package/freerdp/0001-Fix-variable-declaration-in-loop.patch
Fabrice Fontaine 11e899f2b3 package/freerdp: fix build with gcc 4.8
Build is broken with gcc 4.8 since bump to version 2.3.1 in commit
01e78811db due to
5b2f35747b

Fixes:
 - http://autobuild.buildroot.org/results/e8e7d43d6183bb6de7bd2c2b300dbdb89f2052d8

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2021-04-13 21:18:56 +02:00

34 lines
1.2 KiB
Diff

From ddde652460350b962d32036981ff8ed77ed2f1ed Mon Sep 17 00:00:00 2001
From: Armin Novak <armin.novak@thincast.com>
Date: Wed, 16 Sep 2020 09:30:37 +0200
Subject: [PATCH] Fix variable declaration in loop
[Retrieved from:
https://github.com/FreeRDP/FreeRDP/commit/ddde652460350b962d32036981ff8ed77ed2f1ed]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
client/X11/xf_graphics.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/client/X11/xf_graphics.c b/client/X11/xf_graphics.c
index 76fbef5bd6..bf71b563c3 100644
--- a/client/X11/xf_graphics.c
+++ b/client/X11/xf_graphics.c
@@ -386,6 +386,7 @@ static BOOL xf_Pointer_New(rdpContext* context, rdpPointer* pointer)
static void xf_Pointer_Free(rdpContext* context, rdpPointer* pointer)
{
#ifdef WITH_XCURSOR
+ UINT32 i;
xfContext* xfc = (xfContext*)context;
xfPointer* xpointer = (xfPointer*)pointer;
@@ -395,7 +396,7 @@ static void xf_Pointer_Free(rdpContext* context, rdpPointer* pointer)
free(xpointer->cursorWidths);
free(xpointer->cursorHeights);
- for (int i = 0; i < xpointer->nCursors; i++)
+ for (i = 0; i < xpointer->nCursors; i++)
{
XFreeCursor(xfc->display, xpointer->cursors[i]);
}