summaryrefslogtreecommitdiff
path: root/coverage/inorout.py
diff options
context:
space:
mode:
Diffstat (limited to 'coverage/inorout.py')
-rw-r--r--coverage/inorout.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/coverage/inorout.py b/coverage/inorout.py
index 6bdac06e..3bc7e54e 100644
--- a/coverage/inorout.py
+++ b/coverage/inorout.py
@@ -317,6 +317,9 @@ class InOrOut:
disp.reason = reason
return disp
+ if original_filename.startswith('<'):
+ return nope(disp, "not a real original file name")
+
if frame is not None:
# Compiled Python files have two file names: frame.f_code.co_filename is
# the file name at the time the .pyc was compiled. The second name is