aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteven Rostedt <srostedt@redhat.com>2010-02-15 22:58:20 -0500
committerSteven Rostedt <rostedt@goodmis.org>2010-02-15 22:58:20 -0500
commit07beb5bb4454c9576cd1ba51585a492876247863 (patch)
tree62ccbacfa657ff0413af0737e57d4642204ece71
parent4c56b91a773279bedf4e9ec945cf7eca0959f976 (diff)
parse-event: Fix bug where sysname was defined but name was not
If no name is given to the filter, then use the system name as the name and make the system name NULL. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
-rw-r--r--parse-filter.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/parse-filter.c b/parse-filter.c
index 3cfcb4a..f9c3630 100644
--- a/parse-filter.c
+++ b/parse-filter.c
@@ -198,6 +198,12 @@ find_event(struct pevent *pevent, struct event_list **events,
198 struct event_format *event; 198 struct event_format *event;
199 struct event_list *list; 199 struct event_list *list;
200 200
201 if (!event_name) {
202 /* if no name is given, then swap sys and name */
203 event_name = sys_name;
204 sys_name = NULL;
205 }
206
201 event = pevent_find_event_by_name(pevent, sys_name, event_name); 207 event = pevent_find_event_by_name(pevent, sys_name, event_name);
202 if (!event) 208 if (!event)
203 return -1; 209 return -1;