aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/transport/metadata_batch.c
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2017-07-19 15:32:27 -0700
committerGravatar Craig Tiller <ctiller@google.com>2017-07-19 15:32:27 -0700
commit89c1428a60a6c5423ccad9ede60079c5e4cc79ac (patch)
tree73438d93d6b6498f1f6c7d4b5b89a4b9ba59f92f /src/core/lib/transport/metadata_batch.c
parent2e37d001a3bd56cde5f11083cd7f679a50b49022 (diff)
Propagate grpc_millis further
Diffstat (limited to 'src/core/lib/transport/metadata_batch.c')
-rw-r--r--src/core/lib/transport/metadata_batch.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/core/lib/transport/metadata_batch.c b/src/core/lib/transport/metadata_batch.c
index 8f24b8527c..a5ff9c9685 100644
--- a/src/core/lib/transport/metadata_batch.c
+++ b/src/core/lib/transport/metadata_batch.c
@@ -74,7 +74,7 @@ void grpc_metadata_batch_assert_ok(grpc_metadata_batch *batch) {
void grpc_metadata_batch_init(grpc_metadata_batch *batch) {
memset(batch, 0, sizeof(*batch));
- batch->deadline = gpr_inf_future(GPR_CLOCK_REALTIME);
+ batch->deadline = GRPC_MILLIS_INF_FUTURE;
}
void grpc_metadata_batch_destroy(grpc_exec_ctx *exec_ctx,
@@ -268,9 +268,7 @@ void grpc_metadata_batch_clear(grpc_exec_ctx *exec_ctx,
}
bool grpc_metadata_batch_is_empty(grpc_metadata_batch *batch) {
- return batch->list.head == NULL &&
- gpr_time_cmp(gpr_inf_future(batch->deadline.clock_type),
- batch->deadline) == 0;
+ return batch->list.head == NULL && batch->deadline == GRPC_MILLIS_INF_FUTURE;
}
size_t grpc_metadata_batch_size(grpc_metadata_batch *batch) {