diff options
author | Craig Tiller <craig.tiller@gmail.com> | 2015-06-01 20:05:43 -0700 |
---|---|---|
committer | Craig Tiller <craig.tiller@gmail.com> | 2015-06-01 20:05:43 -0700 |
commit | e53a282b26656e713bfbf45b77c95ddcb64f686c (patch) | |
tree | 8b1b9a479fd7a28d8075665a0f6a13e2105db52f /test/core | |
parent | 1b932e77f0b6f99556df03e5147f243d3bce0277 (diff) | |
parent | 8535263b94ee56bbd0e4c9ee168719217459b858 (diff) |
Merge pull request #1862 from nicolasnoble/fixing-tools
Fixing tools compilation.
Diffstat (limited to 'test/core')
-rw-r--r-- | test/core/security/fetch_oauth2.c | 5 | ||||
-rw-r--r-- | test/core/security/print_google_default_creds_token.c | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/test/core/security/fetch_oauth2.c b/test/core/security/fetch_oauth2.c index 7a40fe0dbb..3202df3328 100644 --- a/test/core/security/fetch_oauth2.c +++ b/test/core/security/fetch_oauth2.c @@ -51,7 +51,8 @@ typedef struct { int is_done; } synchronizer; -static void on_oauth2_response(void *user_data, grpc_mdelem **md_elems, +static void on_oauth2_response(void *user_data, + grpc_credentials_md *md_elems, size_t num_md, grpc_credentials_status status) { synchronizer *sync = user_data; char *token; @@ -60,7 +61,7 @@ static void on_oauth2_response(void *user_data, grpc_mdelem **md_elems, gpr_log(GPR_ERROR, "Fetching token failed."); } else { GPR_ASSERT(num_md == 1); - token_slice = md_elems[0]->value->slice; + token_slice = md_elems[0].value; token = gpr_malloc(GPR_SLICE_LENGTH(token_slice) + 1); memcpy(token, GPR_SLICE_START_PTR(token_slice), GPR_SLICE_LENGTH(token_slice)); diff --git a/test/core/security/print_google_default_creds_token.c b/test/core/security/print_google_default_creds_token.c index 76e69ef716..051e8607c4 100644 --- a/test/core/security/print_google_default_creds_token.c +++ b/test/core/security/print_google_default_creds_token.c @@ -49,7 +49,8 @@ typedef struct { int is_done; } synchronizer; -static void on_metadata_response(void *user_data, grpc_mdelem **md_elems, +static void on_metadata_response(void *user_data, + grpc_credentials_md *md_elems, size_t num_md, grpc_credentials_status status) { synchronizer *sync = user_data; @@ -58,7 +59,7 @@ static void on_metadata_response(void *user_data, grpc_mdelem **md_elems, } else { GPR_ASSERT(num_md == 1); printf("\nGot token: %s\n\n", - (const char *)GPR_SLICE_START_PTR(md_elems[0]->value->slice)); + (const char *)GPR_SLICE_START_PTR(md_elems[0].value)); } gpr_mu_lock(&sync->mu); sync->is_done = 1; |