From 43ac18d7189f149d41f46bbd9d9d40d48687ad14 Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Thu, 5 Sep 2013 23:35:02 -0700 Subject: Move global appContext into main() to avoid shadow warnings All other uses of appContext rely on the arguments passed to functions, so move this one to the only scope it's needed in. Signed-off-by: Alan Coopersmith --- xfindproxy.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/xfindproxy.c b/xfindproxy.c index 3541cec..5795327 100644 --- a/xfindproxy.c +++ b/xfindproxy.c @@ -60,8 +60,6 @@ static int PMversionCount = 1; static IcePoVersionRec PMversions[] = {{PM_MAJOR_VERSION, PM_MINOR_VERSION, PMprocessMessages}}; -static XtAppContext appContext; - typedef struct { int status; char *addr; @@ -120,6 +118,7 @@ cvthexkey(char *hexstr, char **ptrp) /* turn hex key string into octets */ int main(int argc, char *argv[]) { + static XtAppContext appContext; IceConn iceConn; IceProtocolSetupStatus setupstat; char *vendor = NULL; -- cgit v1.2.3