1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

M #-: Improve version parser for qemu-nbd

This commit is contained in:
Ruben S. Montero 2020-05-07 17:53:35 +02:00
parent b23a3713a6
commit bdd325a6f8
No known key found for this signature in database
GPG Key ID: A0CEA6FA880A1D87

View File

@ -85,8 +85,7 @@ class Qcow2Mapper < Mapper
return "0.0.0" unless rc.zero?
match_v = out.match(/qemu-nbd ((?:[0-9]+\.?)+) \(/)
match_v = out.match(/qemu-nbd version (.*)$/) if match_v.nil?
match_v = out.match(/qemu-nbd(?: version)? ((?:[0-9]+\.?)+)\s?\(?.*$/)
return "0.0.0" if match_v.nil?