summaryrefslogtreecommitdiff
path: root/src/flake8/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/flake8/utils.py')
-rw-r--r--src/flake8/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/flake8/utils.py b/src/flake8/utils.py
index 29df9bc..e0c221a 100644
--- a/src/flake8/utils.py
+++ b/src/flake8/utils.py
@@ -448,7 +448,7 @@ def matches_filename(path, patterns, log_message, logger):
if not patterns:
return False
basename = os.path.basename(path)
- if fnmatch(basename, patterns):
+ if basename not in {".", ".."} and fnmatch(basename, patterns):
logger.debug(log_message, {"path": basename, "whether": ""})
return True