diff options
author | Bogdan Drutu <bdrutu@google.com> | 2016-04-04 14:33:40 -0700 |
---|---|---|
committer | Bogdan Drutu <bdrutu@google.com> | 2016-04-04 14:33:40 -0700 |
commit | 552aecd0e2045c9e38333e3c5f112c1a7f6c35cc (patch) | |
tree | 8fd0518be2fa026c47fa27997268b02acfc09a46 /src/core/ext | |
parent | 1b7c0a2c5cf27d7a77d9c3476fe6406a98ca3d76 (diff) |
Fix census plugin initialization for census filters.
Diffstat (limited to 'src/core/ext')
-rw-r--r-- | src/core/ext/census/grpc_plugin.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/core/ext/census/grpc_plugin.c b/src/core/ext/census/grpc_plugin.c index 0f15ecb2c2..c6039a3f64 100644 --- a/src/core/ext/census/grpc_plugin.c +++ b/src/core/ext/census/grpc_plugin.c @@ -40,12 +40,12 @@ #include "src/core/lib/surface/channel_init.h" static bool maybe_add_census_filter(grpc_channel_stack_builder *builder, - void *arg_must_be_null) { + void *arg) { const grpc_channel_args *args = grpc_channel_stack_builder_get_channel_arguments(builder); if (grpc_channel_args_is_census_enabled(args)) { return grpc_channel_stack_builder_prepend_filter( - builder, &grpc_client_census_filter, NULL, NULL); + builder, (const grpc_channel_filter *)arg, NULL, NULL); } return true; } @@ -60,9 +60,11 @@ void census_grpc_plugin_init(void) { } } grpc_channel_init_register_stage(GRPC_CLIENT_CHANNEL, INT_MAX, - maybe_add_census_filter, NULL); + maybe_add_census_filter, + (void *)&grpc_client_census_filter); grpc_channel_init_register_stage(GRPC_SERVER_CHANNEL, INT_MAX, - maybe_add_census_filter, NULL); + maybe_add_census_filter, + (void *)&grpc_server_census_filter); } void census_grpc_plugin_shutdown(void) { census_shutdown(); } |