From a2bd0f0a9f7e21125430bef2fa2b3c987849cfb4 Mon Sep 17 00:00:00 2001 From: Sergio Durigan Junior Date: Sun, 20 Mar 2016 14:21:10 -0400 Subject: [PATCH] Improving racy analyzer --- lib/racyanalyze.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/racyanalyze.py b/lib/racyanalyze.py index 79d7792..c229bb6 100644 --- a/lib/racyanalyze.py +++ b/lib/racyanalyze.py @@ -21,7 +21,12 @@ class GDBAnalyzeRacyTests (ShellCommand): racy_tests = p.read_sum_text (self.getLog ('stdio').getText ()) xfails = p.read_xfail (builder, branch) - unique_tests = racy_tests[1]['NONE'] - xfails[1]['FAIL'] + if not racy_tests[1]: + return SUCCESS + elif not xfails[1]: + unique_tests = racy_tests[1]['NONE'] + else: + unique_tests = racy_tests[1]['NONE'] - xfails[1]['FAIL'] msg = "============================\n" for t in unique_tests: @@ -35,7 +40,7 @@ class GDBAnalyzeRacyTests (ShellCommand): s = smtplib.SMTP ('localhost') s.sendmail ('gdb-buildbot@sergiodj.net', - [ 'GDB BuildBot Racy Detector ' ], + [ 'gdb-buildbot@sergiodj.net' ], mail.as_string ()) s.quit ()