X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=ovsdb%2Fdot2pic;h=caca9f8d071234a5eddc020f94d5a9743e1e7679;hb=2e9d1b61b32867cf1343b3f1865610606d83adf5;hp=3e2f30893fc0a94fe3243627d357adb53b219b8c;hpb=fca64c1292812ebea45433b104b9549a02ea268d;p=openvswitch diff --git a/ovsdb/dot2pic b/ovsdb/dot2pic index 3e2f3089..caca9f8d 100755 --- a/ovsdb/dot2pic +++ b/ovsdb/dot2pic @@ -21,9 +21,10 @@ my ($scale) = 1; print ".PS\n"; print "linethick = 1;\n"; while (<>) { - if (/graph (\S+) (\S+) (\S+)/) { - $scale = $1; - } elsif (my ($name, $x, $y, $width, $height, $label, $style, $shape, $color, $fillcolor) = /node (\S+) (\S+) (\S+) (\S+) (\S+) (\S+) (\S+) (\S+) (\S+) (\S+)/) { + if (/^graph/) { + (undef, $scale) = split; + } elsif (/^node/) { + my (undef, $name, $x, $y, $width, $height, $label, $style, $shape, $color, $fillcolor) = split; $x *= $scale; $y *= $scale; $width *= $scale;