diff options
Diffstat (limited to 'test/core/util/port_posix.c')
-rw-r--r-- | test/core/util/port_posix.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/test/core/util/port_posix.c b/test/core/util/port_posix.c index 9bff18d311..cec0eebd33 100644 --- a/test/core/util/port_posix.c +++ b/test/core/util/port_posix.c @@ -66,9 +66,7 @@ static int has_port_been_chosen(int port) { return 0; } -static void free_chosen_ports() { - gpr_free(chosen_ports); -} +static void free_chosen_ports() { gpr_free(chosen_ports); } static void chose_port(int port) { if (chosen_ports == NULL) { @@ -206,7 +204,8 @@ int grpc_pick_unused_port(void) { /* Type of port to first pick in next iteration */ int is_tcp = 1; - int try = 0; + int try + = 0; char *env = gpr_getenv("GRPC_TEST_PORT_SERVER"); if (env) { @@ -219,7 +218,8 @@ int grpc_pick_unused_port(void) { for (;;) { int port; - try++; + try + ++; if (try == 1) { port = getpid() % (65536 - 30000) + 30000; } else if (try <= NUM_RANDOM_PORTS_TO_PICK) { |