ovs-vswitchd.conf.db.5 contains the following sentence:
If the interface cannot be added then Open vSwitch sets this column
to -1.
The '-' in "-1" should be a minus sign, not a hyphen, but the heuristic
in ovsdb-doc wasn't smart enough. This commit improves the heuristic and
fixes the problem.
Found by lintian.
Reported-by: Thomas Goirand <zigo@debian.org>
Reviewed-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Ben Pfaff <blp@nicira.com>
def textToNroff(s, font=r'\fR'):
def escape(match):
c = match.group(0)
- if c == '-':
- if font == r'\fB':
- return r'\-'
+ if c.startswith('-'):
+ if c != '-' or font == r'\fB':
+ return '\\' + c
else:
return '-'
if c == '\\':
raise error.Error("bad escape")
# Escape - \ " ' as needed by nroff.
- s = re.sub('([-"\'\\\\])', escape, s)
+ s = re.sub('(-[0-9]|[-"\'\\\\])', escape, s)
if s.startswith('.'):
s = '\\' + s
return s