This commit is contained in:
J. Nick Koston 2025-07-20 19:57:32 -10:00
parent 04953db51e
commit ad52d80281
No known key found for this signature in database
2 changed files with 5 additions and 7 deletions

View File

@ -991,7 +991,7 @@ class NoiseEncryptionSetKeyRequest : public ProtoDecodableMessage {
#ifdef HAS_PROTO_MESSAGE_DUMP
const char *message_name() const override { return "noise_encryption_set_key_request"; }
#endif
std::string key{}; // Storage for decoded data
std::string key{};
#ifdef HAS_PROTO_MESSAGE_DUMP
void dump_to(std::string &out) const override;
#endif
@ -1914,7 +1914,7 @@ class BluetoothGATTWriteRequest : public ProtoDecodableMessage {
uint64_t address{0};
uint32_t handle{0};
bool response{false};
std::string data{}; // Storage for decoded data
std::string data{};
#ifdef HAS_PROTO_MESSAGE_DUMP
void dump_to(std::string &out) const override;
#endif
@ -1948,7 +1948,7 @@ class BluetoothGATTWriteDescriptorRequest : public ProtoDecodableMessage {
#endif
uint64_t address{0};
uint32_t handle{0};
std::string data{}; // Storage for decoded data
std::string data{};
#ifdef HAS_PROTO_MESSAGE_DUMP
void dump_to(std::string &out) const override;
#endif
@ -2283,7 +2283,7 @@ class VoiceAssistantAudio : public ProtoDecodableMessage {
#endif
const uint8_t *data_ptr_{nullptr};
size_t data_len_{0};
std::string data{}; // Storage for decoded data
std::string data{};
void set_data(const uint8_t *data, size_t len) {
this->data_ptr_ = data;
this->data_len_ = len;

View File

@ -625,9 +625,7 @@ class BytesType(TypeInfo):
# Add std::string storage if message needs decoding
if self.needs_decode:
content.append(
f"std::string {self.field_name}{{}}; // Storage for decoded data"
)
content.append(f"std::string {self.field_name}{{}};")
# Add setter method if message needs encoding
if self.needs_encode: