[promises] Fix fuzzer found uncancelable call bug in client promise code (#34909)

Closes #34909

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/34909 from ctiller:lambda-mcfly 92f759d763
PiperOrigin-RevId: 589989462
pull/35283/head
Craig Tiller 1 year ago committed by Copybara-Service
parent b63a21b419
commit a7e90045db
  1. 2
      src/core/lib/channel/connected_channel.cc
  2. 3
      src/core/lib/surface/call.cc
  3. 51
      test/core/end2end/fuzzers/client_fuzzer_corpus/5061521840340992

@ -411,6 +411,8 @@ auto ConnectedChannelStream::RecvMessages(
}
if (cancel_on_error && !status.ok()) {
incoming_messages.CloseWithError();
} else {
incoming_messages.Close();
}
return Immediate(LoopCtl<absl::Status>(status.status()));
};

@ -2978,7 +2978,8 @@ void ClientPromiseBasedCall::CommitBatch(const grpc_op* ops, size_t nops,
StartRecvMessage(
op, completion,
[this]() {
return server_initial_metadata_.receiver.AwaitClosed();
return Race(server_initial_metadata_.receiver.AwaitClosed(),
server_to_client_messages_.receiver.AwaitClosed());
},
&server_to_client_messages_.receiver, false, spawner);
break;

@ -0,0 +1,51 @@
api_actions {
create_call {
propagation_mask: 6
method {
value: "~"
}
timeout: 34816
}
}
api_actions {
queue_batch {
operations {
send_initial_metadata {
}
}
operations {
send_message {
}
}
operations {
receive_message {
}
}
}
}
api_actions {
create_server {
}
}
api_actions {
disable_tracer: "("
}
api_actions {
destroy_call {
}
}
api_actions {
poll_cq {
}
}
api_actions {
}
api_actions {
shutdown_server {
}
}
config_vars {
verbosity: "\364\204\204\204\364\204\204\204\364\204\204\204\364\204\204\204\364\204\204\204\364\204\204\204\364\204\204\204\364\204\204\204\004"
stacktrace_minloglevel: "yyyyyyyyyyyyy&yyyyyyy\177\014"
experiments: 1099511626496
}
Loading…
Cancel
Save