trace-cruncher: Fix the class 'event' constructor
PATCH 1/1 trace-cruncher: Fix the class 'event' constructor
The constructor must fail in the case when the event is not found on the system.
Signed-off-by Yordan Karadzhov (VMware) <[email protected]>
--- tracecruncher/ft_utils.py | 2 ++ 1 file changed, 2 insertions(+)
tracecruncher/ft_utils.py +2 -0
@@ -46,6 +46,8 @@ class event: self.instance_list = [] if static: self.evt_id = find_event_id(system, name) + if self.evt_id < 0: + raise ValueError('Faild to find event {0}/{1}'.format(system, name)) else: self.evt_id = -1
Signature · 1 line
2.30.2