$OpenBSD: patch-rdesktop_c,v 1.1 2011/06/23 15:17:13 sebastia Exp $

fix build with gcc-2.95

--- rdesktop.c.orig	Wed Jun 22 16:10:33 2011
+++ rdesktop.c	Wed Jun 22 16:11:31 2011
@@ -465,6 +465,7 @@ main(int argc, char *argv[])
 	char *locale = NULL;
 	int username_option = 0;
 	RD_BOOL geometry_option = False;
+	struct sigaction act;
 #ifdef WITH_RDPSND
 	char *rdpsnd_optarg = NULL;
 #endif
@@ -480,7 +481,6 @@ main(int argc, char *argv[])
 #endif
 
 	/* Ignore SIGPIPE, since we are using popen() */
-	struct sigaction act;
 	memset(&act, 0, sizeof(act));
 	act.sa_handler = SIG_IGN;
 	sigemptyset(&act.sa_mask);
@@ -893,6 +893,7 @@ main(int argc, char *argv[])
 
 	if (!username_option)
 	{
+		int pwlen;
 		pw = getpwuid(getuid());
 		if ((pw == NULL) || (pw->pw_name == NULL))
 		{
@@ -900,7 +901,7 @@ main(int argc, char *argv[])
 			return EX_OSERR;
 		}
 		/* +1 for trailing \0 */
-		int pwlen = strlen(pw->pw_name) + 1;
+		pwlen = strlen(pw->pw_name) + 1;
 		g_username = (char *) xmalloc(pwlen);
 		STRNCPY(g_username, pw->pw_name, pwlen);
 	}
