diff options
Diffstat (limited to 'test/core/iomgr/udp_server_test.c')
-rw-r--r-- | test/core/iomgr/udp_server_test.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/test/core/iomgr/udp_server_test.c b/test/core/iomgr/udp_server_test.c index 74b78958b0..471d5b50c7 100644 --- a/test/core/iomgr/udp_server_test.c +++ b/test/core/iomgr/udp_server_test.c @@ -49,8 +49,7 @@ static grpc_pollset g_pollset; static int g_number_of_reads = 0; static int g_number_of_bytes_read = 0; -static void on_connect(void *arg, grpc_endpoint *udp) { -} +static void on_connect(void *arg, grpc_endpoint *udp) {} static void on_read(int fd, grpc_udp_server_cb new_transport_cb, void *cb_arg) { char read_buffer[512]; @@ -122,7 +121,8 @@ static void test_receive(int number_of_clients) { memset(&addr, 0, sizeof(addr)); addr.ss_family = AF_INET; - GPR_ASSERT(grpc_udp_server_add_port(s, (struct sockaddr *)&addr, addr_len, on_read)); + GPR_ASSERT( + grpc_udp_server_add_port(s, (struct sockaddr *)&addr, addr_len, on_read)); svrfd = grpc_udp_server_get_fd(s, 0); GPR_ASSERT(svrfd >= 0); @@ -146,7 +146,8 @@ static void test_receive(int number_of_clients) { while (g_number_of_reads == number_of_reads_before && gpr_time_cmp(deadline, gpr_now(deadline.clock_type)) > 0) { grpc_pollset_worker worker; - grpc_pollset_work(&g_pollset, &worker, deadline); + grpc_pollset_work(&g_pollset, &worker, gpr_now(GPR_CLOCK_MONOTONIC), + deadline); } GPR_ASSERT(g_number_of_reads == number_of_reads_before + 1); close(clifd); |