summaryrefslogtreecommitdiffstats
path: root/Lib/email
diff options
context:
space:
mode:
authoroda-gitso <105083118+oda-gitso@users.noreply.github.com>2022-05-23 16:10:18 (GMT)
committerGitHub <noreply@github.com>2022-05-23 16:10:18 (GMT)
commit71abeb0895f7563dc5ac4b4f077a8f87dab57e7a (patch)
tree45880b0769ef95030d43aa3929b64110e339b866 /Lib/email
parent949dbf97ba09da3cfb243d5ad7f90967ad15f354 (diff)
downloadcpython-71abeb0895f7563dc5ac4b4f077a8f87dab57e7a.zip
cpython-71abeb0895f7563dc5ac4b4f077a8f87dab57e7a.tar.gz
cpython-71abeb0895f7563dc5ac4b4f077a8f87dab57e7a.tar.bz2
gh-93010: InvalidHeaderError used but nonexistent (#93015)
* fix issue 93010 Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Diffstat (limited to 'Lib/email')
-rw-r--r--Lib/email/_header_value_parser.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/email/_header_value_parser.py b/Lib/email/_header_value_parser.py
index 8a8fb8b..e637e6d 100644
--- a/Lib/email/_header_value_parser.py
+++ b/Lib/email/_header_value_parser.py
@@ -2379,7 +2379,7 @@ def get_section(value):
digits += value[0]
value = value[1:]
if digits[0] == '0' and digits != '0':
- section.defects.append(errors.InvalidHeaderError(
+ section.defects.append(errors.InvalidHeaderDefect(
"section number has an invalid leading 0"))
section.number = int(digits)
section.append(ValueTerminal(digits, 'digits'))