Skip to content

Commit

Permalink
lib.sh: Workaround sof-test output alignment issue
Browse files Browse the repository at this point in the history
If sof-test test case is run manually and locally,
the output of sof-test is messy, the lines are not
aligned left at the beginning of each line, some
lines start in the middle of a line, which makes
the output log hard to follow.

This patch helps to workaround the above issue.

Link: thesofproject#1151

Signed-off-by: Chao Song <[email protected]>
  • Loading branch information
Chao Song committed Jan 17, 2024
1 parent bc3ced5 commit 70748bd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion case-lib/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,9 @@ func_mtrace_collect()
dlogi "Starting ${mtraceCmd[*]} >& $clogfile &"
# Cleaned up by func_exit_handler() in hijack.sh
# shellcheck disable=SC2024
sudo "${mtraceCmd[@]}" >& "$clogfile" &
# The use of 'bash -c' is a workaround for an issue,
# see https://github.com/thesofproject/sof-test/issues/1151
sudo bash -c "${mtraceCmd[*]} >& $clogfile &"
}

func_lib_log_post_process()
Expand Down

0 comments on commit 70748bd

Please sign in to comment.