diff --git a/src/core/lib/gprpp/thd_windows.cc b/src/core/lib/gprpp/thd_windows.cc index 703da74e051..b7828660eba 100644 --- a/src/core/lib/gprpp/thd_windows.cc +++ b/src/core/lib/gprpp/thd_windows.cc @@ -147,7 +147,8 @@ class ThreadInternalsWindows namespace grpc_core { Thread::Thread(const char* thd_name, void (*thd_body)(void* arg), void* arg, - bool* success, const Options& options) : options_(options) { + bool* success, const Options& options) + : options_(options) { bool outcome = false; impl_ = grpc_core::New(thd_body, arg, &outcome, options); diff --git a/test/core/util/port.cc b/test/core/util/port.cc index 303306de452..14d648b7eaf 100644 --- a/test/core/util/port.cc +++ b/test/core/util/port.cc @@ -34,6 +34,7 @@ #include "src/core/lib/http/httpcli.h" #include "src/core/lib/iomgr/resolve_address.h" #include "src/core/lib/iomgr/sockaddr_utils.h" +#include "src/core/lib/surface/init.h" #include "test/core/util/port_server_client.h" static int* chosen_ports = nullptr; @@ -67,6 +68,7 @@ static void free_chosen_ports(void) { grpc_free_port_using_server(chosen_ports[i]); } grpc_shutdown(); + grpc_maybe_wait_for_async_shutdown(); gpr_free(chosen_ports); }