From a441ac98a1fcec7c438eef2e13d1ac3321933ea9 Mon Sep 17 00:00:00 2001 From: Jakob Lykke Andersen Date: Wed, 18 May 2016 09:38:27 +0900 Subject: [PATCH] Fix crash on any-references with unicode. Fixes sphinx-doc/sphinx#2555. --- CHANGES | 1 + sphinx/domains/cpp.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index d4e5f952bf..f5eb1e2b3a 100644 --- a/CHANGES +++ b/CHANGES @@ -54,6 +54,7 @@ Bugs fixed * #2526: LaTeX writer crashes if the section having only images * #2522: Sphinx touches mo files under installed directory that caused permission error. * #2536: C++, fix crash when an immediately nested scope has the same name as the current scope. +* #2555: Fix crash on any-references with unicode. Release 1.4.1 (released Apr 12, 2016) diff --git a/sphinx/domains/cpp.py b/sphinx/domains/cpp.py index 2d28a71fbc..7d41d65709 100644 --- a/sphinx/domains/cpp.py +++ b/sphinx/domains/cpp.py @@ -4100,7 +4100,7 @@ class CPPDomain(Domain): parser.assert_end() except DefinitionError as e: warner.warn('Unparseable C++ cross-reference: %r\n%s' - % (target, str(e.description))) + % (target, text_type(e.description))) return None, None parentKey = node.get("cpp:parent_key", None) rootSymbol = self.data['root_symbol']