Underscores in headings seem to be ignored, but let's play it safe and escape the name as well.
Signed-off-by: Ahmad Fatoum <[email protected]> --- Documentation/gen_commands.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/gen_commands.py b/Documentation/gen_commands.py index f8a7ed7b879f..1a7353a854cd 100755 --- a/Documentation/gen_commands.py +++ b/Documentation/gen_commands.py @@ -104,9 +104,9 @@ def gen_rst(name, cmd): out.append('.. _command_%s:' % name) out.append('') if 'c_desc' in cmd: - out.append("%s - %s" % (name, ''.join(cmd['c_desc']).strip())) + out.append("%s - %s" % (string_escape(name), ''.join(cmd['c_desc']).strip())) else: - out.append("%s" % (name,)) + out.append("%s" % (string_escape(name),)) out.append('=' * len(out[-1])) out.append('') if 'c_opts' in cmd: -- 2.47.3
