Skip to content

Commit ba77abb

Browse files
author
Jyri Sarha
committed
debug_stream: text_msg: exception: Skip useless " ** " prefix
Skip useless " ** " prefix from exception dumps to save byte is in the debug_stream buffer. Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
1 parent 128e258 commit ba77abb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/debug/debug_stream/debug_stream_text_msg.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,11 @@ static void ds_exception_dump(const char *format, va_list args)
7373
if (reports_sent_cpu[arch_proc_id()] > 0)
7474
return;
7575

76+
/* Skip useless " ** " prefix to save bytes */
77+
if (strlen(format) >= 4 &&
78+
format[0] == ' ' && format[1] == '*' && format[2] == '*' && format[3] == ' ')
79+
format += 4;
80+
7681
len = vsnprintf(ds_buf.text + ds_pos, sizeof(ds_buf.text) - ds_pos, format, args);
7782
if (len < 0) {
7883
ds_pos = 0;

0 commit comments

Comments
 (0)