Skip to content

Commit bbd2051

Browse files
Merged from 7.43.1.dev0
Guard against reference sections without names. [from revision 19892] - Legacy-Id: 19894
2 parents bc4c5dc + d4fbaa2 commit bbd2051

1 file changed

Lines changed: 6 additions & 5 deletions

File tree

ietf/utils/xmldraft.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,12 @@ def _document_name(self, anchor):
6969

7070
def _reference_section_type(self, section_name):
7171
"""Determine reference type from name of references section"""
72-
section_name = section_name.lower()
73-
if 'normative' in section_name:
74-
return self.REF_TYPE_NORMATIVE
75-
elif 'informative' in section_name:
76-
return self.REF_TYPE_INFORMATIVE
72+
if section_name:
73+
section_name = section_name.lower()
74+
if 'normative' in section_name:
75+
return self.REF_TYPE_NORMATIVE
76+
elif 'informative' in section_name:
77+
return self.REF_TYPE_INFORMATIVE
7778
return self.REF_TYPE_UNKNOWN
7879

7980
def get_refs(self):

0 commit comments

Comments
 (0)