1
0
mirror of https://github.com/esphome/esphome.git synced 2026-02-08 08:41:59 +00:00

Merge branch 'api_avoid_copies' into integration

This commit is contained in:
J. Nick Koston
2025-12-30 10:44:37 -10:00

View File

@@ -1722,7 +1722,7 @@ void APIConnection::on_home_assistant_state_response(const HomeAssistantStateRes
memcpy(state_buf, msg.state, msg.state_len);
}
state_buf[msg.state_len] = '\0';
it.callback(StringRef(state_buf));
it.callback(StringRef(state_buf, msg.state_len));
}
}
#endif