[api] Add zero-copy support for noise encryption key requests (#12405)

This commit is contained in:
J. Nick Koston authored and GitHub committed 2025-12-20 06:47:30 -10:00
1 parent 64269334ce
commit 40eb898814
7 files changed
+21 -12

No files matched your search

+5 -2
View File
@@ -858,9 +858,12 @@ void SubscribeLogsResponse::calculate_size(ProtoSize &size) const {
#ifdef USE_API_NOISE
bool NoiseEncryptionSetKeyRequest::decode_length(uint32_t field_id, ProtoLengthDelimited value) {
switch (field_id) {
case 1:
this->key = value.as_string();
case 1: {
// Use raw data directly to avoid allocation
this->key = value.data();
this->key_len = value.size();
break;
}
default:
return false;
}