aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/iomgr/timer_uv.cc
diff options
context:
space:
mode:
authorGravatar Yash Tibrewal <yashkt@google.com>2017-11-13 15:37:58 -0800
committerGravatar Yash Tibrewal <yashkt@google.com>2017-11-14 01:36:28 -0800
commit75122c23578e24417dcf64081c737571a9fc2dbc (patch)
treef4b8491964ec0508a5826490628c9f87b82c3326 /src/core/lib/iomgr/timer_uv.cc
parent36cd68f0d543b9024c84eff82319890a791de7f6 (diff)
Address some PR comments
Diffstat (limited to 'src/core/lib/iomgr/timer_uv.cc')
-rw-r--r--src/core/lib/iomgr/timer_uv.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/core/lib/iomgr/timer_uv.cc b/src/core/lib/iomgr/timer_uv.cc
index 94601d99af..6edd4169f1 100644
--- a/src/core/lib/iomgr/timer_uv.cc
+++ b/src/core/lib/iomgr/timer_uv.cc
@@ -51,7 +51,6 @@ void run_expired_timer(uv_timer_t* handle) {
timer->pending = 0;
GRPC_CLOSURE_SCHED(timer->closure, GRPC_ERROR_NONE);
stop_uv_timer(handle);
- grpc_exec_ctx_finish();
}
void grpc_timer_init(grpc_timer* timer, grpc_millis deadline,
@@ -60,13 +59,13 @@ void grpc_timer_init(grpc_timer* timer, grpc_millis deadline,
uv_timer_t* uv_timer;
GRPC_UV_ASSERT_SAME_THREAD();
timer->closure = closure;
- if (deadline <= grpc_exec_ctx_now()) {
+ if (deadline <= ExecCtx::Get()->Now()) {
timer->pending = 0;
GRPC_CLOSURE_SCHED(timer->closure, GRPC_ERROR_NONE);
return;
}
timer->pending = 1;
- timeout = (uint64_t)(deadline - grpc_exec_ctx_now());
+ timeout = (uint64_t)(deadline - ExecCtx::Get()->Now());
uv_timer = (uv_timer_t*)gpr_malloc(sizeof(uv_timer_t));
uv_timer_init(uv_default_loop(), uv_timer);
uv_timer->data = timer;