fix version detection in str_to_version (#9767)

This commit is contained in:
sairuk 2022-05-17 00:49:09 +10:00 committed by GitHub
parent a450478483
commit a68e611f07
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -39,7 +39,7 @@ function str_to_version(str)
return val
end
local cnt = 10000
for word in string.gmatch(str, '([^.]+)') do
for word in string.gmatch(str, '([^.-]+)') do
if(tonumber(word) == nil) then
return val
end