projects
/
kconfig-hardened-check.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f0541cf
)
Fix pylint warnings in _open
author
Alexander Popov
<alex.popov@linux.com>
Sun, 12 May 2024 15:21:44 +0000
(18:21 +0300)
committer
Alexander Popov
<alex.popov@linux.com>
Sun, 12 May 2024 15:21:44 +0000
(18:21 +0300)
kernel_hardening_checker/__init__.py
patch
|
blob
|
history
diff --git
a/kernel_hardening_checker/__init__.py
b/kernel_hardening_checker/__init__.py
index 1522d4a87aec946af42884ef0e933e5b7aa8ae02..0e4c15263eacca4da305247311e162ad42f2bb98 100644
(file)
--- a/
kernel_hardening_checker/__init__.py
+++ b/
kernel_hardening_checker/__init__.py
@@
-24,10
+24,8
@@
from .engine import populate_with_data, perform_checks, override_expected_value
def _open(file: str, *args, **kwargs) -> TextIO:
if file.endswith('.gz'):
- f = gzip.open(file, *args, **kwargs)
- else:
- f = open(file, *args, **kwargs)
- return f
+ return gzip.open(file, *args, **kwargs)
+ return open(file, *args, **kwargs)
def detect_arch(fname: str, archs: List[str]) -> Tuple: