lib/ovsimager/ipnetns.rb in ovsimager-0.0.2 vs lib/ovsimager/ipnetns.rb in ovsimager-0.0.3
- old
+ new
@@ -34,10 +34,10 @@
end
private
def parse(out, args)
out.split(/\n(?=[^ \s])/).map do |iface|
- if iface.match(/^(\d+):\s+(\S+?):+/)
+ if iface.match(/^(\d+):\s+(\S+?)(?:@\S+)?:+/)
params = {:id => $1, :name => $2}
yield params, iface, args
else
STDERR.puts "IPNetNS: parse error: #{iface}"
{}