Update copyrights, clang-fmt

pull/4606/head
Craig Tiller 9 years ago
parent c18b471cc0
commit 560e5f8aa3
  1. 5
      src/core/httpcli/httpcli_security_connector.c
  2. 6
      src/core/security/client_auth_filter.c
  3. 4
      src/core/security/credentials.c
  4. 4
      src/core/security/jwt_verifier.c
  5. 19
      src/core/security/security_connector.c
  6. 7
      src/core/security/security_connector.h
  7. 4
      src/core/surface/init.c
  8. 4
      src/core/transport/static_metadata.c
  9. 4
      src/core/transport/static_metadata.h
  10. 8
      test/core/end2end/end2end_nosec_tests.c
  11. 6
      test/core/end2end/end2end_tests.c
  12. 6
      test/core/support/alloc_test.c

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -84,8 +84,7 @@ static void httpcli_ssl_do_handshake(grpc_exec_ctx *exec_ctx,
}
static void httpcli_ssl_check_peer(grpc_exec_ctx *exec_ctx,
grpc_security_connector *sc,
tsi_peer peer,
grpc_security_connector *sc, tsi_peer peer,
grpc_security_peer_check_cb cb,
void *user_data) {
grpc_httpcli_ssl_channel_security_connector *c =

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -232,8 +232,8 @@ static void auth_start_transport_op(grpc_exec_ctx *exec_ctx,
}
sec_ctx = op->context[GRPC_CONTEXT_SECURITY].value;
GRPC_AUTH_CONTEXT_UNREF(sec_ctx->auth_context, "client auth filter");
sec_ctx->auth_context = GRPC_AUTH_CONTEXT_REF(
chand->auth_context, "client_auth_filter");
sec_ctx->auth_context =
GRPC_AUTH_CONTEXT_REF(chand->auth_context, "client_auth_filter");
}
if (op->send_initial_metadata != NULL) {

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -180,7 +180,7 @@ void grpc_server_credentials_set_auth_metadata_processor(
"grpc_server_credentials_set_auth_metadata_processor("
"creds=%p, "
"processor=grpc_auth_metadata_processor { process: %p, state: %p })",
3, (creds, (void*)(gpr_intptr)processor.process, processor.state));
3, (creds, (void *)(gpr_intptr)processor.process, processor.state));
if (creds == NULL) return;
if (creds->processor.destroy != NULL && creds->processor.state != NULL) {
creds->processor.destroy(creds->processor.state);

@ -443,8 +443,8 @@ static BIGNUM *bignum_from_base64(const char *b64) {
gpr_log(GPR_ERROR, "Invalid base64 for big num.");
return NULL;
}
result =
BN_bin2bn(GPR_SLICE_START_PTR(bin), TSI_SIZE_AS_SIZE(GPR_SLICE_LENGTH(bin)), NULL);
result = BN_bin2bn(GPR_SLICE_START_PTR(bin),
TSI_SIZE_AS_SIZE(GPR_SLICE_LENGTH(bin)), NULL);
gpr_slice_unref(bin);
return result;
}

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -316,8 +316,7 @@ grpc_channel_security_connector *grpc_fake_channel_security_connector_create(
c->base.is_client_side = 1;
c->base.url_scheme = GRPC_FAKE_SECURITY_URL_SCHEME;
c->base.vtable = &fake_channel_vtable;
c->request_metadata_creds =
grpc_call_credentials_ref(request_metadata_creds);
c->request_metadata_creds = grpc_call_credentials_ref(request_metadata_creds);
c->check_call_host = fake_channel_check_call_host;
return c;
}
@ -500,9 +499,10 @@ static grpc_security_status ssl_check_peer(grpc_security_connector *sc,
return GRPC_SECURITY_OK;
}
static void ssl_channel_check_peer(
grpc_exec_ctx *exec_ctx, grpc_security_connector *sc, tsi_peer peer,
grpc_security_peer_check_cb cb, void *user_data) {
static void ssl_channel_check_peer(grpc_exec_ctx *exec_ctx,
grpc_security_connector *sc, tsi_peer peer,
grpc_security_peer_check_cb cb,
void *user_data) {
grpc_ssl_channel_security_connector *c =
(grpc_ssl_channel_security_connector *)sc;
grpc_security_status status;
@ -516,9 +516,10 @@ static void ssl_channel_check_peer(
tsi_peer_destruct(&peer);
}
static void ssl_server_check_peer(
grpc_exec_ctx *exec_ctx, grpc_security_connector *sc, tsi_peer peer,
grpc_security_peer_check_cb cb, void *user_data) {
static void ssl_server_check_peer(grpc_exec_ctx *exec_ctx,
grpc_security_connector *sc, tsi_peer peer,
grpc_security_peer_check_cb cb,
void *user_data) {
grpc_auth_context *auth_context = NULL;
grpc_security_status status = ssl_check_peer(sc, NULL, &peer, &auth_context);
tsi_peer_destruct(&peer);

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -40,10 +40,7 @@
/* --- status enum. --- */
typedef enum {
GRPC_SECURITY_OK = 0,
GRPC_SECURITY_ERROR
} grpc_security_status;
typedef enum { GRPC_SECURITY_OK = 0, GRPC_SECURITY_ERROR } grpc_security_status;
/* --- URL schemes. --- */

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -83,7 +83,7 @@ static int g_number_of_plugins = 0;
void grpc_register_plugin(void (*init)(void), void (*destroy)(void)) {
GRPC_API_TRACE("grpc_register_plugin(init=%p, destroy=%p)", 2,
((void*)(gpr_intptr)init, (void*)(gpr_intptr)destroy));
((void*)(gpr_intptr)init, (void*)(gpr_intptr)destroy));
GPR_ASSERT(g_number_of_plugins != MAX_PLUGINS);
g_all_of_the_plugins[g_number_of_plugins].init = init;
g_all_of_the_plugins[g_number_of_plugins].destroy = destroy;

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -30,7 +30,7 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/
/*
* WARNING: Auto-generated code.
*

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -30,7 +30,7 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/
/*
* WARNING: Auto-generated code.
*

@ -2,7 +2,7 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -33,8 +33,6 @@
*
*/
/* This file is auto-generated */
#include "test/core/end2end/end2end_tests.h"
@ -77,7 +75,8 @@ extern void simple_delayed_request(grpc_end2end_test_config config);
extern void simple_request(grpc_end2end_test_config config);
extern void trailing_metadata(grpc_end2end_test_config config);
void grpc_end2end_tests(int argc, char **argv, grpc_end2end_test_config config) {
void grpc_end2end_tests(int argc, char **argv,
grpc_end2end_test_config config) {
int i;
if (argc <= 1) {
@ -264,4 +263,3 @@ void grpc_end2end_tests(int argc, char **argv, grpc_end2end_test_config config)
abort();
}
}

@ -33,8 +33,6 @@
*
*/
/* This file is auto-generated */
#include "test/core/end2end/end2end_tests.h"
@ -78,7 +76,8 @@ extern void simple_delayed_request(grpc_end2end_test_config config);
extern void simple_request(grpc_end2end_test_config config);
extern void trailing_metadata(grpc_end2end_test_config config);
void grpc_end2end_tests(int argc, char **argv, grpc_end2end_test_config config) {
void grpc_end2end_tests(int argc, char **argv,
grpc_end2end_test_config config) {
int i;
if (argc <= 1) {
@ -270,4 +269,3 @@ void grpc_end2end_tests(int argc, char **argv, grpc_end2end_test_config config)
abort();
}
}

@ -1,6 +1,6 @@
/*
*
* Copyright 2015, Google Inc.
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -48,8 +48,8 @@ static void test_custom_allocs() {
gpr_allocation_functions fns = {fake_malloc, fake_realloc, fake_free};
gpr_set_allocation_functions(fns);
GPR_ASSERT((void*)(size_t)0xdeadbeef == gpr_malloc(0xdeadbeef));
GPR_ASSERT((void*)(size_t)0xcafed00d == gpr_realloc(0, 0xcafed00d));
GPR_ASSERT((void *)(size_t)0xdeadbeef == gpr_malloc(0xdeadbeef));
GPR_ASSERT((void *)(size_t)0xcafed00d == gpr_realloc(0, 0xcafed00d));
gpr_free(&addr_to_free);
GPR_ASSERT(addr_to_free == 0xdeadd00d);

Loading…
Cancel
Save