aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/iomgr/iomgr_uv.c
diff options
context:
space:
mode:
authorGravatar murgatroid99 <mlumish@google.com>2017-07-18 13:20:55 -0700
committerGravatar murgatroid99 <mlumish@google.com>2017-07-18 13:20:55 -0700
commitb8e07ad780ceb0bae7c431d0de1c6343bf275ceb (patch)
tree67e75eac7260c75acdf4088446493f9249c778f4 /src/core/lib/iomgr/iomgr_uv.c
parent87116f449985cd49728326ecbdb7293cc522b8ff (diff)
Add asserts that uv calls all run on the same thread
Diffstat (limited to 'src/core/lib/iomgr/iomgr_uv.c')
-rw-r--r--src/core/lib/iomgr/iomgr_uv.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/lib/iomgr/iomgr_uv.c b/src/core/lib/iomgr/iomgr_uv.c
index 7a99a6efdd..c484a39c54 100644
--- a/src/core/lib/iomgr/iomgr_uv.c
+++ b/src/core/lib/iomgr/iomgr_uv.c
@@ -22,14 +22,18 @@
#include "src/core/lib/debug/trace.h"
#include "src/core/lib/iomgr/executor.h"
+#include "src/core/lib/iomgr/iomgr_uv.h"
#include "src/core/lib/iomgr/pollset_uv.h"
#include "src/core/lib/iomgr/tcp_uv.h"
+gpr_thd_id grpc_init_thread;
+
void grpc_iomgr_platform_init(void) {
grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT;
grpc_pollset_global_init();
grpc_register_tracer("tcp", &grpc_tcp_trace);
grpc_executor_set_threading(&exec_ctx, false);
+ grpc_init_thread = gpr_thd_currentid();
grpc_exec_ctx_finish(&exec_ctx);
}
void grpc_iomgr_platform_flush(void) {}