summaryrefslogtreecommitdiffstats
path: root/generic/tclIOCmd.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2017-04-10 09:35:51 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2017-04-10 09:35:51 (GMT)
commit1d506e42aefb665e5243f2ca4cbaeb86c4c4036e (patch)
tree522d542088c176e4ae0d354561db29bc681b6ba4 /generic/tclIOCmd.c
parentdc32232f03c2fa6dfb75ee8ca0ac4767a2a4db12 (diff)
parent22946a554a465a115602ba3324fb7fd8ea5590b4 (diff)
downloadtcl-1d506e42aefb665e5243f2ca4cbaeb86c4c4036e.zip
tcl-1d506e42aefb665e5243f2ca4cbaeb86c4c4036e.tar.gz
tcl-1d506e42aefb665e5243f2ca4cbaeb86c4c4036e.tar.bz2
merge (minor style issues from) trunktip_468
Diffstat (limited to 'generic/tclIOCmd.c')
-rw-r--r--generic/tclIOCmd.c33
1 files changed, 24 insertions, 9 deletions
diff --git a/generic/tclIOCmd.c b/generic/tclIOCmd.c
index 55685e3..712f773 100644
--- a/generic/tclIOCmd.c
+++ b/generic/tclIOCmd.c
@@ -1629,19 +1629,34 @@ Tcl_SocketObjCmd(
return TCL_ERROR;
}
- // Set the options to their default value if the user didn't override their
- // value.
- if (reusep == -1) reusep = 0;
- if (reusea == -1) reusea = 1;
+ /*
+ * Set the options to their default value if the user didn't override
+ * their value.
+ */
- // Build the bitset with the flags values.
- if (reusea)
+ if (reusep == -1) {
+ reusep = 0;
+ }
+ if (reusea == -1) {
+ reusea = 1;
+ }
+
+ /*
+ * Build the bitset with the flags values.
+ */
+
+ if (reusea) {
flags |= TCL_TCPSERVER_REUSEADDR;
- if (reusep)
+ }
+ if (reusep) {
flags |= TCL_TCPSERVER_REUSEPORT;
+ }
+
+ /*
+ * All the arguments should have been parsed by now, 'a' points to the
+ * last one, the port number.
+ */
- // All the arguments should have been parsed by now, 'a' points to the last
- // one, the port number.
if (a != objc-1) {
goto wrongNumArgs;
}