Merge pull request #9905 from The-Loeki/patch-2

qemu vnc: hardcoded lowerbound leaves negative ports
This commit is contained in:
Wilken Rivera 2020-09-08 10:17:53 -04:00 committed by GitHub
commit 2da89db272
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -76,9 +76,9 @@ func getCommandArgs(bootDrive string, state multistep.StateBag) ([]string, error
var vnc string
if !config.VNCUsePassword {
vnc = fmt.Sprintf("%s:%d", vncIP, vncPort-5900)
vnc = fmt.Sprintf("%s:%d", vncIP, vncPort-config.VNCPortMin)
} else {
vnc = fmt.Sprintf("%s:%d,password", vncIP, vncPort-5900)
vnc = fmt.Sprintf("%s:%d,password", vncIP, vncPort-config.VNCPortMin)
}
if config.QMPEnable {