diff options
author | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2020-01-05 22:46:24 +0100 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2020-01-05 22:46:24 +0100 |
commit | a261b72435d7d30dbe36529a51fc53f6ade34dff (patch) | |
tree | fde666b59abbe3bdf0ed574147344c0d25075b03 /nx-X11/programs/Xserver/hw/nxagent/Binder.c | |
parent | 0e2b7479cd4567128fbcd975e5376744d78cd416 (diff) | |
parent | adca0cc92abed6f7f6184b91d807a4befb80e856 (diff) | |
download | nx-libs-a261b72435d7d30dbe36529a51fc53f6ade34dff.tar.gz nx-libs-a261b72435d7d30dbe36529a51fc53f6ade34dff.tar.bz2 nx-libs-a261b72435d7d30dbe36529a51fc53f6ade34dff.zip |
Merge branch 'uli42-pr/code_cleanup' into 3.6.x
Attributes GH PR #869: https://github.com/ArcticaProject/nx-libs/pull/869
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/Binder.c')
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Binder.c | 29 |
1 files changed, 11 insertions, 18 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.c b/nx-X11/programs/Xserver/hw/nxagent/Binder.c index 1a6c4e969..518c016c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.c @@ -46,19 +46,13 @@ 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. + * 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 +63,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", @@ -78,8 +72,8 @@ int nxagentCheckBinder(int argc, char *argv[], int i) /* * The NX options must be specified in the DISPLAY - * environment. Check if the display specified on - * the command line matches the NX virtual display. + * environment. Check if the display specified on the command line + * matches the NX virtual display. */ display = getenv("DISPLAY"); @@ -108,8 +102,8 @@ int nxagentCheckBinder(int argc, char *argv[], int i) #endif /* - * Save the proxy options. They will be later - * used to create the transport. + * Save the proxy options. They will be later used to create the + * transport. */ nxagentChangeOption(Rootless, False); @@ -117,10 +111,9 @@ int nxagentCheckBinder(int argc, char *argv[], int i) nxagentChangeOption(Binder, True); /* - * FIXME: This now points to the buffer that was - * returned by getenv(). It is to be decided how - * to handle the values of type string in the - * Options repository. + * FIXME: This now points to the buffer that was returned by + * getenv(). It is to be decided how to handle the values of type + * string in the Options repository. */ nxagentChangeOption(BinderOptions, display); |