Fixed OpenSSH patch version comparison. (#74)

This commit is contained in:
Joe Testa
2020-10-19 18:49:52 -04:00
parent 2bb31b306f
commit 83d8014a50
2 changed files with 9 additions and 7 deletions

View File

@ -83,8 +83,8 @@ class Software:
if not re.match(r'^test\d.*$', spatch):
spatch = 'z{}'.format(spatch)
elif self.product == Product.OpenSSH:
mx1 = re.match(r'^p\d(.*)', opatch)
mx2 = re.match(r'^p\d(.*)', spatch)
mx1 = re.match(r'^p(\d).*', opatch)
mx2 = re.match(r'^p(\d).*', spatch)
if not (bool(mx1) and bool(mx2)):
if mx1 is not None:
opatch = mx1.group(1)