提交 f95e0818 编写于 作者: J Jiri Olsa 提交者: Arnaldo Carvalho de Melo

perf tests: Check for mkstemp return value in dso-data test

Adding check for mkstemp return error value in dso-data test.
Reported-by: NArnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: NJiri Olsa <jolsa@redhat.com>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1352508412-16914-13-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
上级 c81251e8
......@@ -26,6 +26,10 @@ static char *test_file(int size)
unsigned char *buf;
fd = mkstemp(templ);
if (fd < 0) {
perror("mkstemp failed");
return NULL;
}
buf = malloc(size);
if (!buf) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册