#2465: latex builder fails in case no caption option is provided to toctree directive

This commit is contained in:
Takeshi KOMIYA 2016-04-22 11:05:12 +09:00
parent becc54702a
commit 88322af1ea
2 changed files with 2 additions and 1 deletions

View File

@ -22,6 +22,7 @@ Bugs fixed
* #2456: C++, fix crash related to document merging (e.g., singlehtml and Latex builders).
* #2446: latex(pdf) sets local tables of contents (or more generally topic nodes) in unbreakable boxes, causes overflow at bottom
* #2476: Omit MathJax markers if :nowrap: is given
* #2465: latex builder fails in case no caption option is provided to toctree directive
Release 1.4.1 (released Apr 12, 2016)

View File

@ -137,7 +137,7 @@ class LaTeXBuilder(Builder):
tree = self.env.get_doctree(indexfile)
contentsname = None
for toctree in tree.traverse(addnodes.toctree):
if toctree['caption']:
if 'caption' in toctree:
contentsname = toctree['caption']
break