Remove unused parameter warning (12 of 20)

pull/20649/head
Vijay Pai 5 years ago
parent a0ad4081cb
commit c3faf1c3b8
  1. 4
      test/core/security/secure_endpoint_test.cc
  2. 2
      test/core/security/security_connector_test.cc
  3. 10
      test/core/security/spiffe_security_connector_test.cc
  4. 4
      test/core/security/ssl_server_fuzzer.cc
  5. 4
      test/core/slice/slice_test.cc
  6. 3
      test/core/surface/completion_queue_test.cc
  7. 5
      test/core/surface/completion_queue_threading_test.cc
  8. 4
      test/core/surface/concurrent_connectivity_test.cc
  9. 2
      test/core/surface/lame_client_test.cc
  10. 4
      test/core/transport/byte_stream_test.cc

@ -166,7 +166,7 @@ static grpc_endpoint_test_config configs[] = {
clean_up},
};
static void inc_call_ctr(void* arg, grpc_error* error) {
static void inc_call_ctr(void* arg, grpc_error* /*error*/) {
++*static_cast<int*>(arg);
}
@ -202,7 +202,7 @@ static void test_leftover(grpc_endpoint_test_config config, size_t slice_size) {
clean_up();
}
static void destroy_pollset(void* p, grpc_error* error) {
static void destroy_pollset(void* p, grpc_error* /*error*/) {
grpc_pollset_destroy(static_cast<grpc_pollset*>(p));
}

@ -343,7 +343,7 @@ static grpc_ssl_roots_override_result override_roots_success(
}
static grpc_ssl_roots_override_result override_roots_permanent_failure(
char** pem_root_certs) {
char** /*pem_root_certs*/) {
return GRPC_SSL_ROOTS_OVERRIDE_FAIL_PERMANENTLY;
}

@ -46,27 +46,27 @@ void SetKeyMaterials(grpc_tls_key_materials_config* config) {
(const grpc_ssl_pem_key_cert_pair**)key_cert_pair, 1);
}
int CredReloadSuccess(void* config_user_data,
int CredReloadSuccess(void* /*config_user_data*/,
grpc_tls_credential_reload_arg* arg) {
SetKeyMaterials(arg->key_materials_config);
arg->status = GRPC_SSL_CERTIFICATE_CONFIG_RELOAD_NEW;
return 0;
}
int CredReloadFail(void* config_user_data,
int CredReloadFail(void* /*config_user_data*/,
grpc_tls_credential_reload_arg* arg) {
arg->status = GRPC_SSL_CERTIFICATE_CONFIG_RELOAD_FAIL;
return 0;
}
int CredReloadUnchanged(void* config_user_data,
int CredReloadUnchanged(void* /*config_user_data*/,
grpc_tls_credential_reload_arg* arg) {
arg->status = GRPC_SSL_CERTIFICATE_CONFIG_RELOAD_UNCHANGED;
return 0;
}
int CredReloadAsync(void* config_user_data,
grpc_tls_credential_reload_arg* arg) {
int CredReloadAsync(void* /*config_user_data*/,
grpc_tls_credential_reload_arg* /*arg*/) {
return 1;
}

@ -32,9 +32,9 @@ bool squelch = true;
// Turning this on will fail the leak check.
bool leak_check = false;
static void discard_write(grpc_slice slice) {}
static void discard_write(grpc_slice /*slice*/) {}
static void dont_log(gpr_log_func_args* args) {}
static void dont_log(gpr_log_func_args* /*args*/) {}
struct handshake_state {
bool done_callback_called;

@ -61,7 +61,7 @@ static void test_slice_malloc_returns_something_sensible(void) {
}
}
static void do_nothing(void* ignored) {}
static void do_nothing(void* /*ignored*/) {}
static void test_slice_new_returns_something_sensible(void) {
uint8_t x;
@ -96,7 +96,7 @@ static void test_slice_new_with_user_data(void) {
static int do_nothing_with_len_1_calls = 0;
static void do_nothing_with_len_1(void* ignored, size_t len) {
static void do_nothing_with_len_1(void* /*ignored*/, size_t len) {
GPR_ASSERT(len == 1);
do_nothing_with_len_1_calls++;
}

@ -129,7 +129,8 @@ static void test_wait_empty(void) {
}
}
static void do_nothing_end_completion(void* arg, grpc_cq_completion* c) {}
static void do_nothing_end_completion(void* /*arg*/,
grpc_cq_completion* /*c*/) {}
static void test_cq_end_op(void) {
grpc_event ev;

@ -60,7 +60,8 @@ static void shutdown_and_destroy(grpc_completion_queue* cc) {
grpc_completion_queue_destroy(cc);
}
static void do_nothing_end_completion(void* arg, grpc_cq_completion* c) {}
static void do_nothing_end_completion(void* /*arg*/,
grpc_cq_completion* /*c*/) {}
struct thread_state {
grpc_completion_queue* cc;
@ -136,7 +137,7 @@ gpr_timespec ten_seconds_time(void) {
return grpc_timeout_seconds_to_deadline(10);
}
static void free_completion(void* arg, grpc_cq_completion* completion) {
static void free_completion(void* /*arg*/, grpc_cq_completion* completion) {
gpr_free(completion);
}

@ -105,7 +105,7 @@ void server_thread(void* vargs) {
}
static void on_connect(void* vargs, grpc_endpoint* tcp,
grpc_pollset* accepting_pollset,
grpc_pollset* /*accepting_pollset*/,
grpc_tcp_server_acceptor* acceptor) {
gpr_free(acceptor);
struct server_thread_args* args =
@ -160,7 +160,7 @@ void bad_server_thread(void* vargs) {
gpr_free(args->addr);
}
static void done_pollset_shutdown(void* pollset, grpc_error* error) {
static void done_pollset_shutdown(void* pollset, grpc_error* /*error*/) {
grpc_pollset_destroy(static_cast<grpc_pollset*>(pollset));
gpr_free(pollset);
}

@ -39,7 +39,7 @@ static void* tag(intptr_t x) { return (void*)x; }
static grpc_closure transport_op_cb;
static void do_nothing(void* arg, grpc_error* error) {}
static void do_nothing(void* /*arg*/, grpc_error* /*error*/) {}
void test_transport_op(grpc_channel* channel) {
grpc_core::ExecCtx exec_ctx;

@ -37,7 +37,9 @@ namespace {
// SliceBufferByteStream tests
//
void NotCalledClosure(void* arg, grpc_error* error) { GPR_ASSERT(false); }
void NotCalledClosure(void* /*arg*/, grpc_error* /*error*/) {
GPR_ASSERT(false);
}
TEST(SliceBufferByteStream, Basic) {
grpc_core::ExecCtx exec_ctx;

Loading…
Cancel
Save