2
0
mirror of https://gitlab.com/apparmor/apparmor synced 2025-09-02 23:35:37 +00:00

fix whitespace and indentation in several files

This commit is contained in:
Christian Boltz
2019-08-12 23:27:41 +02:00
parent 2e304f82fc
commit e246568819
7 changed files with 14 additions and 14 deletions

View File

@@ -398,7 +398,7 @@ def main():
# If a TTY then assume running in test mode and fix output width # If a TTY then assume running in test mode and fix output width
if not sys.stdout.isatty(): if not sys.stdout.isatty():
parser.formatter_class=lambda prog: argparse.HelpFormatter(prog, width=80) parser.formatter_class = lambda prog: argparse.HelpFormatter(prog, width=80)
args = parser.parse_args() args = parser.parse_args()

View File

@@ -197,7 +197,7 @@ def filter_processes(processes, status):
def find_apparmorfs(): def find_apparmorfs():
'''Finds AppArmor mount point''' '''Finds AppArmor mount point'''
for p in open("/proc/mounts","rb").readlines(): for p in open("/proc/mounts", "rb").readlines():
if p.split()[2].decode() == "securityfs" and \ if p.split()[2].decode() == "securityfs" and \
os.path.exists(os.path.join(p.split()[1].decode(), "apparmor")): os.path.exists(os.path.join(p.split()[1].decode(), "apparmor")):
return os.path.join(p.split()[1].decode(), "apparmor") return os.path.join(p.split()[1].decode(), "apparmor")

View File

@@ -140,7 +140,7 @@ class BaseRule(object):
'''check if other_rule is covered by this rule object''' '''check if other_rule is covered by this rule object'''
if not type(other_rule) == type(self): if not type(other_rule) == type(self):
raise AppArmorBug('Passes %s instead of %s' % (str(other_rule),self.__class__.__name__)) raise AppArmorBug('Passes %s instead of %s' % (str(other_rule), self.__class__.__name__))
if check_allow_deny and self.deny != other_rule.deny: if check_allow_deny and self.deny != other_rule.deny:
return False return False