From: Alexander Popov Date: Fri, 20 Jul 2018 16:36:52 +0000 (+0300) Subject: Don't return the result from Opt.check(), we don't use it X-Git-Tag: v0.5.2~88^2~3 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=da2ad76655e19340e0482cae09965dcf96f70758;p=kconfig-hardened-check.git Don't return the result from Opt.check(), we don't use it --- diff --git a/kconfig-hardened-check.py b/kconfig-hardened-check.py index 2668664..35cf743 100755 --- a/kconfig-hardened-check.py +++ b/kconfig-hardened-check.py @@ -40,21 +40,15 @@ class Opt: if self.expected == self.state: self.result = 'OK' - return True, self.result - - - if self.state is None: + elif self.state is None: if self.expected == 'is not set': self.result = 'OK: not found' - return True, self.result else: error_count += 1 self.result = 'FAIL: not found' - return False, self.result - - error_count += 1 - self.result = 'FAIL: "' + self.state + '"' - return False, self.result + else: + error_count += 1 + self.result = 'FAIL: "' + self.state + '"' def __repr__(self): return '{} = {}'.format(self.name, self.state)