浏览代码

ftracetest: Fix to show descriptions on dash

The ftracetest doesn't show testcase's descriptions when
it is executed on dash. This fixes that to show the
descriptions on dash correctly by passing it via a variable
instead of directly passing the grep command output.

Link: http://lkml.kernel.org/r/20141204194116.7376.78940.stgit@localhost.localdomain

Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Masami Hiramatsu 10 年之前
父节点
当前提交
36922d133c
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      tools/testing/selftests/ftrace/ftracetest

+ 2 - 1
tools/testing/selftests/ftrace/ftracetest

@@ -135,7 +135,8 @@ TOTAL_RESULT=0
 CASENO=0
 CASENO=0
 testcase() { # testfile
 testcase() { # testfile
   CASENO=$((CASENO+1))
   CASENO=$((CASENO+1))
-  prlog -n "[$CASENO]"`grep "^#[ \t]*description:" $1 | cut -f2 -d:`
+  desc=`grep "^#[ \t]*description:" $1 | cut -f2 -d:`
+  prlog -n "[$CASENO]$desc"
 }
 }
 
 
 eval_result() { # retval sigval
 eval_result() { # retval sigval