perf tools: Incorrect use of snprintf results in SEGV