perf tests: Do not assume that readlink() returns a null terminated string
authorTommi Rantala <tommi.t.rantala@nokia.com>
Wed, 22 Mar 2017 13:06:21 +0000 (15:06 +0200)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 27 Mar 2017 18:35:56 +0000 (15:35 -0300)
commit0e6ba11511aef91ba8e2528ddc681d88922d7b0b
treebfd066a73068f97059534cd3965a29a6041ea2ed
parent5a2342111c68e623e27ee7ea3d0492d8dad6bda0
perf tests: Do not assume that readlink() returns a null terminated string

Ensure that the string in buf is null terminated.

Signed-off-by: Tommi Rantala <tommi.t.rantala@nokia.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20170322130624.21881-4-tommi.t.rantala@nokia.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/tests/sdt.c