diff options
author | 2017-11-13 16:44:02 -0800 | |
---|---|---|
committer | 2017-11-13 16:44:02 -0800 | |
commit | 68bb1bf7480e87005220003985da19ea0a0929d0 (patch) | |
tree | c434576b07f94f427925dd7f7dfba4dbdeecee31 /test/core/end2end/tests/shutdown_finishes_calls.cc | |
parent | 6bf73e8cf6d9d2ede844ab628a0b88000ffc9afa (diff) | |
parent | b0bad8f3864dc9c8745736fe68efe513b2b84932 (diff) |
Merge branch 'master' of https://github.com/grpc/grpc into tracing++
Diffstat (limited to 'test/core/end2end/tests/shutdown_finishes_calls.cc')
-rw-r--r-- | test/core/end2end/tests/shutdown_finishes_calls.cc | 29 |
1 files changed, 15 insertions, 14 deletions
diff --git a/test/core/end2end/tests/shutdown_finishes_calls.cc b/test/core/end2end/tests/shutdown_finishes_calls.cc index 26a53e5161..fce23f3b6a 100644 --- a/test/core/end2end/tests/shutdown_finishes_calls.cc +++ b/test/core/end2end/tests/shutdown_finishes_calls.cc @@ -53,14 +53,14 @@ static gpr_timespec five_seconds_from_now(void) { static void drain_cq(grpc_completion_queue* cq) { grpc_event ev; do { - ev = grpc_completion_queue_next(cq, five_seconds_from_now(), NULL); + ev = grpc_completion_queue_next(cq, five_seconds_from_now(), nullptr); } while (ev.type != GRPC_QUEUE_SHUTDOWN); } static void shutdown_client(grpc_end2end_test_fixture* f) { if (!f->client) return; grpc_channel_destroy(f->client); - f->client = NULL; + f->client = nullptr; } static void end_test(grpc_end2end_test_fixture* f) { @@ -77,8 +77,9 @@ static void test_early_server_shutdown_finishes_inflight_calls( grpc_end2end_test_config config) { grpc_call* c; grpc_call* s; - grpc_end2end_test_fixture f = begin_test( - config, "test_early_server_shutdown_finishes_inflight_calls", NULL, NULL); + grpc_end2end_test_fixture f = + begin_test(config, "test_early_server_shutdown_finishes_inflight_calls", + nullptr, nullptr); cq_verifier* cqv = cq_verifier_create(f.cq); grpc_op ops[6]; grpc_op* op; @@ -93,10 +94,10 @@ static void test_early_server_shutdown_finishes_inflight_calls( gpr_timespec deadline = five_seconds_from_now(); c = grpc_channel_create_call( - f.client, NULL, GRPC_PROPAGATE_DEFAULTS, f.cq, + f.client, nullptr, GRPC_PROPAGATE_DEFAULTS, f.cq, grpc_slice_from_static_string("/foo"), get_host_override_slice("foo.test.google.fr:1234", config), deadline, - NULL); + nullptr); GPR_ASSERT(c); grpc_metadata_array_init(&initial_metadata_recv); @@ -108,27 +109,27 @@ static void test_early_server_shutdown_finishes_inflight_calls( op = ops; op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; - op->data.send_initial_metadata.metadata = NULL; + op->data.send_initial_metadata.metadata = nullptr; op->flags = 0; - op->reserved = NULL; + op->reserved = nullptr; op++; op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT; op->flags = 0; - op->reserved = NULL; + op->reserved = nullptr; op++; op->op = GRPC_OP_RECV_INITIAL_METADATA; op->data.recv_initial_metadata.recv_initial_metadata = &initial_metadata_recv; op->flags = 0; - op->reserved = NULL; + op->reserved = nullptr; op++; op->op = GRPC_OP_RECV_STATUS_ON_CLIENT; op->data.recv_status_on_client.trailing_metadata = &trailing_metadata_recv; op->data.recv_status_on_client.status = &status; op->data.recv_status_on_client.status_details = &details; op->flags = 0; - op->reserved = NULL; + op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, (size_t)(op - ops), tag(1), NULL); + error = grpc_call_start_batch(c, ops, (size_t)(op - ops), tag(1), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -143,9 +144,9 @@ static void test_early_server_shutdown_finishes_inflight_calls( op->op = GRPC_OP_RECV_CLOSE_ON_SERVER; op->data.recv_close_on_server.cancelled = &was_cancelled; op->flags = 0; - op->reserved = NULL; + op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, (size_t)(op - ops), tag(102), NULL); + error = grpc_call_start_batch(s, ops, (size_t)(op - ops), tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); /* shutdown and destroy the server */ |