From 07beb5bb4454c9576cd1ba51585a492876247863 Mon Sep 17 00:00:00 2001 From: Steven Rostedt Date: Mon, 15 Feb 2010 22:58:20 -0500 Subject: 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 --- parse-filter.c | 6 ++++++ 1 file changed, 6 insertions(+) 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, struct event_format *event; struct event_list *list; + if (!event_name) { + /* if no name is given, then swap sys and name */ + event_name = sys_name; + sys_name = NULL; + } + event = pevent_find_event_by_name(pevent, sys_name, event_name); if (!event) return -1; -- cgit v1.2.2