Remove the ability to specify a string on cancel: it was broken and unused; will restore later

pull/2263/head
Craig Tiller 10 years ago
parent 69f561681e
commit 0d4836d2c5
  1. 2
      src/core/transport/metadata.c
  2. 4
      src/core/transport/transport.c
  3. 1
      src/core/transport/transport.h
  4. 5
      src/core/transport/transport_op_string.c

@ -120,7 +120,7 @@ static void unlock(grpc_mdctx *ctx) {
if (ctx->refs == 0) {
/* uncomment if you're having trouble diagnosing an mdelem leak to make
things clearer (slows down destruction a lot, however) */
/* gc_mdtab(ctx); */
gc_mdtab(ctx);
if (ctx->mdtab_count && ctx->mdtab_count == ctx->mdtab_free) {
discard_metadata(ctx);
}

@ -112,8 +112,8 @@ void grpc_transport_op_add_cancellation(grpc_transport_op *op,
grpc_mdstr *message) {
if (op->cancel_with_status == GRPC_STATUS_OK) {
op->cancel_with_status = status;
op->cancel_message = message;
} else if (message) {
}
if (message) {
grpc_mdstr_unref(message);
}
}

@ -77,7 +77,6 @@ typedef struct grpc_transport_op {
grpc_pollset *bind_pollset;
grpc_status_code cancel_with_status;
grpc_mdstr *cancel_message;
/* Indexes correspond to grpc_context_index enum values */
grpc_call_context_element *context;

@ -144,11 +144,6 @@ char *grpc_transport_op_string(grpc_transport_op *op) {
first = 0;
gpr_asprintf(&tmp, "CANCEL:%d", op->cancel_with_status);
gpr_strvec_add(&b, tmp);
if (op->cancel_message) {
gpr_asprintf(&tmp, ";msg='%s'",
grpc_mdstr_as_c_string(op->cancel_message));
gpr_strvec_add(&b, tmp);
}
}
out = gpr_strvec_flatten(&b, NULL);

Loading…
Cancel
Save