From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Ingo Molnar <mingo@kernel.org>
Cc: linux-kernel@vger.kernel.org,
"Steven Rostedt (Red Hat)" <rostedt@goodmis.org>,
Andrew Morton <akpm@linux-foundation.org>,
Jiri Olsa <jolsa@redhat.com>, Namhyung Kim <namhyung@kernel.org>,
Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: [PATCH 22/25] tools lib traceevent: Free filter tokens in process_filter()
Date: Tue, 24 Mar 2015 13:19:37 -0300 [thread overview]
Message-ID: <1427213980-9015-23-git-send-email-acme@kernel.org> (raw)
In-Reply-To: <1427213980-9015-1-git-send-email-acme@kernel.org>
From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
valgrind showed that the filter token wasn't being freed properly in
process_filter().
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: http://lkml.kernel.org/r/20150324135923.817723903@goodmis.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/lib/traceevent/parse-filter.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tools/lib/traceevent/parse-filter.c b/tools/lib/traceevent/parse-filter.c
index b50234402fc2..0144b3d1bb77 100644
--- a/tools/lib/traceevent/parse-filter.c
+++ b/tools/lib/traceevent/parse-filter.c
@@ -1058,6 +1058,7 @@ process_filter(struct event_format *event, struct filter_arg **parg,
*parg = current_op;
else
*parg = current_exp;
+ free(token);
return PEVENT_ERRNO__UNBALANCED_PAREN;
}
break;
@@ -1168,6 +1169,7 @@ process_filter(struct event_format *event, struct filter_arg **parg,
*parg = current_op;
+ free(token);
return 0;
fail_alloc:
--
1.9.3
next prev parent reply other threads:[~2015-03-24 16:22 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-24 16:19 [GIT PULL 00/25] perf/core improvements and fixes Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 01/25] perf tools: Use kmod_path__parse in map_groups__set_modules_path_dir Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 02/25] perf tools: Use kmod_path__parse in decompress_kmodule Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 03/25] perf tools: Use kmod_path__parse in is_kernel_module Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 04/25] perf tools: Remove compressed argument from is_kernel_module Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 05/25] perf tools: Remove is_kmodule_extension function Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 06/25] perf tools: Try to lookup kernel module map before creating one Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 07/25] perf annotate: Allow annotation for decompressed kernel modules Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 08/25] perf tools: Remove (null) value of "Sort order" for perf mem report Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 09/25] perf probe: Fix to get ummapped symbol address on kernel Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 10/25] tools lib traceevent: Factor out allocating and processing args Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 11/25] perf kmem: Print big numbers using thousands' group Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 13/25] perf target: Simplify handling of strerror_r return Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 14/25] perf symbols: Save DSO loading errno to better report errors Arnaldo Carvalho de Melo
2015-03-27 10:32 ` Borislav Petkov
2015-03-27 14:37 ` Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 15/25] tools lib traceevent: Handle NULL comm name Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 16/25] tools lib traceevent: Copy trace_clock and free it Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 17/25] tools lib traceevent: Handle %z in bprint format Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 18/25] tools lib traceevent: Add pevent_data_pid_from_comm() Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 19/25] tools lib traceevent: Make plugin options either string or boolean Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 21/25] tools lib traceevent: Add way to find sub buffer boundary Arnaldo Carvalho de Melo
2015-03-24 16:19 ` Arnaldo Carvalho de Melo [this message]
2015-03-24 16:19 ` [PATCH 23/25] tools lib traceevent: Add support for __print_array() Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 24/25] perf diff: Add kallsyms option Arnaldo Carvalho de Melo
2015-03-24 16:19 ` [PATCH 25/25] perf tools: Add pid/tid filtering to report and script commands Arnaldo Carvalho de Melo
2015-03-24 16:26 ` [GIT PULL 00/25] perf/core improvements and fixes Ingo Molnar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1427213980-9015-23-git-send-email-acme@kernel.org \
--to=acme@kernel.org \
--cc=acme@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung@kernel.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.