diff options
author | ncteisen <ncteisen@gmail.com> | 2018-08-28 12:53:57 -0700 |
---|---|---|
committer | ncteisen <ncteisen@gmail.com> | 2018-08-28 12:53:57 -0700 |
commit | 4b5b019d5644affef122e06c6898811286850b8d (patch) | |
tree | 73c601dc31c436e3d800a846d08b9ace7ff05235 /src/core/lib/iomgr/exec_ctx.cc | |
parent | b8f030bc0b507903e9d156fb44d161015273d0c6 (diff) | |
parent | ee65a5eaee45a765d1d4176a797bb8288faeb180 (diff) |
Merge branch 'master' of https://github.com/grpc/grpc into channelz-subchannels
Diffstat (limited to 'src/core/lib/iomgr/exec_ctx.cc')
-rw-r--r-- | src/core/lib/iomgr/exec_ctx.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/core/lib/iomgr/exec_ctx.cc b/src/core/lib/iomgr/exec_ctx.cc index 5d5c355ff9..d68fa0714b 100644 --- a/src/core/lib/iomgr/exec_ctx.cc +++ b/src/core/lib/iomgr/exec_ctx.cc @@ -109,6 +109,12 @@ grpc_closure_scheduler* grpc_schedule_on_exec_ctx = &exec_ctx_scheduler; namespace grpc_core { GPR_TLS_CLASS_DEF(ExecCtx::exec_ctx_); +// WARNING: for testing purposes only! +void ExecCtx::TestOnlyGlobalInit(gpr_timespec new_val) { + g_start_time = new_val; + gpr_tls_init(&exec_ctx_); +} + void ExecCtx::GlobalInit(void) { g_start_time = gpr_now(GPR_CLOCK_MONOTONIC); gpr_tls_init(&exec_ctx_); |