From: Steven Rostedt Date: Tue, 22 Apr 2014 23:23:30 +0000 (-0400) Subject: tools lib traceevent: Fix memory leak in pretty_print() X-Git-Tag: omap-for-v3.16/pm-signed~27^2~2^2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=de04f8657de9d3351a2d5880f1f7080b23b798cf;p=pandora-kernel.git tools lib traceevent: Fix memory leak in pretty_print() Commit 12e55569a244 "tools lib traceevent: Use helper trace-seq in print functions like kernel does" added a extra trace_seq helper to process string arguments like the kernel does it. But the difference between the kernel and the userspace library is that the kernel's trace_seq structure has a static allocated buffer. The userspace one has a dynamically allocated one. It requires a trace_seq_destroy(), otherwise it produces a nasty memory leak. Cc: stable@vger.kernel.org # 3.14+ Signed-off-by: Steven Rostedt Link: http://lkml.kernel.org/r/20140422192330.6bb09bf8@gandalf.local.home Signed-off-by: Jiri Olsa --- Reading git-diff-tree failed