Skip proto message dump for log and camera responses

In debug builds (HAS_PROTO_MESSAGE_DUMP), skip dump logging for
SubscribeLogsResponse (recursive logging risk) and CameraImageResponse
(high-frequency image data noise). This matches the base branch behavior
where both bypassed dump logging via direct send_message_impl() calls.
This commit is contained in:
J. Nick Koston
2026-03-04 07:24:59 -10:00
parent 765075b1d0
commit a1df4f80e1
+6 -1
View File
@@ -1869,7 +1869,12 @@ bool APIConnection::try_to_clear_buffer(bool log_out_of_space) {
bool APIConnection::send_message_(uint32_t payload_size, uint8_t message_type, MessageEncodeFn encode_fn,
const void *msg) {
#ifdef HAS_PROTO_MESSAGE_DUMP
{
// Skip dump for log messages (recursive logging risk) and camera frames (high-frequency noise)
if (message_type != SubscribeLogsResponse::MESSAGE_TYPE
#ifdef USE_CAMERA
&& message_type != CameraImageResponse::MESSAGE_TYPE
#endif
) {
auto *proto_msg = static_cast<const ProtoMessage *>(msg);
DumpBuffer dump_buf;
this->log_send_message_(proto_msg->message_name(), proto_msg->dump_to(dump_buf));