aboutsummaryrefslogtreecommitdiff
path: root/nx-X11
diff options
context:
space:
mode:
authorUlrich Sibiller <uli42@gmx.de>2019-10-23 00:19:22 +0200
committerUlrich Sibiller <uli42@gmx.de>2020-01-05 22:37:35 +0100
commit44138137bb2d15362c67056685a3e6caccbb0918 (patch)
treec7ff21f775a4d3eb30b7868b49ac97f33b3917e8 /nx-X11
parentd86cb00b6891d4afbb030eb32ccca1d1410c2e97 (diff)
downloadnx-libs-44138137bb2d15362c67056685a3e6caccbb0918.tar.gz
nx-libs-44138137bb2d15362c67056685a3e6caccbb0918.tar.bz2
nx-libs-44138137bb2d15362c67056685a3e6caccbb0918.zip
Binder.c: scope improvements
Diffstat (limited to 'nx-X11')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Binder.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.c b/nx-X11/programs/Xserver/hw/nxagent/Binder.c
index 1a6c4e969..247fb9d77 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Binder.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.c
@@ -46,19 +46,14 @@ int nxagentCheckBinder(int argc, char *argv[], int i)
{
if (++i < argc)
{
- char *display;
- char *found;
-
- int port;
-
- display = argv[i];
+ char *display = argv[i];
/*
* Check if a display specification follows
* the -B switch.
*/
- found = rindex(display, ':');
+ char *found = rindex(display, ':');
if (found == NULL || *(found + 1) == '\0' ||
isdigit(*(found + 1)) == 0)
@@ -69,7 +64,7 @@ int nxagentCheckBinder(int argc, char *argv[], int i)
return 0;
}
- port = atoi(found + 1);
+ int port = atoi(found + 1);
#ifdef TEST
fprintf(stderr, "nxagentCheckBinder: Identified agent display port [%d].\n",