• Wolfgang Bumiller's avatar
    bridgevlanport: replace sed pipe with substitution · 0bba4496
    Wolfgang Bumiller authored
    The previous code stripped *all* combinations of zero or
    more letters and digits followed by a dot of an interface
    name to retrieve the VLANID. At the same time the supposedly
    opposite code for IF_VLAN_RAW_DEVICE only actually extracts
    the part up to the *first* dot. Thus an interface named
    'a.b.0' would have a VLANID of 0 and a raw device name of
    just 'a'.
    I also don't see a reason to limit the removed portions to
    alphanumeric characters. I.e. an interface named tap-test.0
    would result in a VLANID of 'tap-0' and an
    IF_VLAN_RAW_DEVICE of 'test'.
    
    A simple shell substitution seems to do a much better job
    and is more efficient than forking out two processes with a
    pipe.
    0bba4496
Name
Last commit
Last update
PVE Loading commit data...
aplinfo Loading commit data...
bin Loading commit data...
debian Loading commit data...
po Loading commit data...
www Loading commit data...
.gitignore Loading commit data...
Makefile Loading commit data...
bridgevlan Loading commit data...
bridgevlanport Loading commit data...
copyright Loading commit data...
country.pl Loading commit data...
defines.mk Loading commit data...
mtu Loading commit data...
pve-apt.conf Loading commit data...
pve-repo-ca-certificates.crt Loading commit data...
pve-sources.list Loading commit data...
repoid.pl Loading commit data...
spice-example-sh Loading commit data...
vlan Loading commit data...
vlan-down Loading commit data...
vzdump-hook-script.pl Loading commit data...
vzdump.conf Loading commit data...
vznet.conf Loading commit data...