mirror of
https://github.com/esphome/esphome.git
synced 2025-10-07 04:13:47 +01:00
handle >999
This commit is contained in:
@@ -356,8 +356,7 @@ class Logger : public Component {
|
||||
copy_string(buffer, pos, tag);
|
||||
buffer[pos++] = ':';
|
||||
// Format line number without modulo operations (passed by value, safe to mutate)
|
||||
if [[unlikely]]
|
||||
(line > 999) {
|
||||
if (line > 999) [[unlikely]] {
|
||||
int thousands = line / 1000;
|
||||
buffer[pos++] = '0' + thousands;
|
||||
line -= thousands * 1000;
|
||||
|
Reference in New Issue
Block a user