From: Mauro Carvalho Chehab Date: Thu, 23 May 2019 10:43:43 +0000 (-0300) Subject: docs: cdomain.py: get rid of a warning since version 1.8 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=42f6ebd827832e62a37350ffad776ea785a2486b;p=openwrt%2Fstaging%2Fblogic.git docs: cdomain.py: get rid of a warning since version 1.8 There's a new warning about a deprecation function. Add a logic at cdomain.py to avoid that. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Jonathan Corbet --- diff --git a/Documentation/sphinx/cdomain.py b/Documentation/sphinx/cdomain.py index cf13ff3a656c..cbac8e608dc4 100644 --- a/Documentation/sphinx/cdomain.py +++ b/Documentation/sphinx/cdomain.py @@ -48,7 +48,10 @@ major, minor, patch = sphinx.version_info[:3] def setup(app): - app.override_domain(CDomain) + if (major == 1 and minor < 8): + app.override_domain(CDomain) + else: + app.add_domain(CDomain, override=True) return dict( version = __version__,