From 731edf84d8fb72a09de384521876c03ab07368b3 Mon Sep 17 00:00:00 2001 From: Pawel Wodkowski Date: Wed, 8 Mar 2017 20:46:31 +0100 Subject: [PATCH] autotest_common.sh: fix backtrace printing Line number regex match all numbers starting from X eg: 10 will match 100 101 102... Fix this by adding space to regex. Change-Id: Id594550618fea74a22f50033eac101439253a371 Signed-off-by: Pawel Wodkowski --- scripts/autotest_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/autotest_common.sh b/scripts/autotest_common.sh index 149c50f30..3d34d4db1 100755 --- a/scripts/autotest_common.sh +++ b/scripts/autotest_common.sh @@ -208,7 +208,7 @@ function print_backtrace() { echo "in $src:$line_nr -> $func()" echo " ..." nl -w 4 -ba -nln $src | grep -B 5 -A 5 "^$line_nr" | \ - sed "s/^/ /g" | sed "s/^ $line_nr/=> $line_nr/g" + sed "s/^/ /g" | sed "s/^ $line_nr /=> $line_nr /g" echo " ..." done echo ""