Commit 84227fbf authored by Ell's avatar Ell

tools: in performance-log-viewer.py, fix "function()" predicate ...

... when not specifying a thread-ID
parent c7f17307
......@@ -727,12 +727,13 @@ class FindSamplesPopover (Gtk.Popover):
for i in range (len (samples)):
try:
def match_thread (thread, id, state = None):
return (type (id) == int and \
id == thread.id) or \
(type (id) == str and \
thread.name and \
re.fullmatch (id, thread.name)) and \
(state is None or \
return (id is None or \
(type (id) == int and \
id == thread.id) or \
(type (id) == str and \
thread.name and \
re.fullmatch (id, thread.name))) and \
(state is None or \
re.fullmatch (state, str (thread.state)))
def thread (id, state = None):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment