Reverse default port count virtualbox argument

As we know the exact versions that used the old `sataportcount` option, it's safe to assume we want to use the newer `portcount` option for everything else.

Reversed the option check and use the `portcount` option by default. Prevents needing to update this for future major versions of VirtualBox.
pull/7174/head
Ed Maxwell-Lyte 7 years ago
parent 65b3e67951
commit e40c90423f

@ -24,9 +24,9 @@ func (d *VBox42Driver) CreateSATAController(vmName string, name string, portcoun
return err
}
portCountArg := "--sataportcount"
if strings.HasPrefix(version, "4.3") || strings.HasPrefix(version, "5.") || strings.HasPrefix(version, "6.") {
portCountArg = "--portcount"
portCountArg = "--portcount"
if strings.HasPrefix(version, "1.") || strings.HasPrefix(version, "2.") || strings.HasPrefix(version, "3.") || strings.HasPrefix(version, "4.0") || strings.HasPrefix(version, "4.1") || strings.HasPrefix(version, "4.2") {
portCountArg := "--sataportcount"
}
command := []string{

Loading…
Cancel
Save