Skip to content
This repository was archived by the owner on Oct 3, 2021. It is now read-only.

Commit f4fc919

Browse files
committed
fix crash of check-script when called with python3 check.py.
An empty dirname crashes the script. The fix uses '.' instead of ''.
1 parent f32eef1 commit f4fc919

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

c/check.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -660,7 +660,7 @@ def main(num_processes):
660660
logging.warning("Missing python-yaml, not all checks can be executed")
661661

662662

663-
main_directory = os.path.relpath(os.path.dirname(__file__))
663+
main_directory = os.path.relpath(os.path.dirname(__file__) or '.')
664664
_check_known_errors_consistent(main_directory)
665665
entries = sorted(os.listdir(main_directory))
666666
all_patterns_re = (

0 commit comments

Comments
 (0)