Print instead of Printf with no dynamic first variable.

This commit is contained in:
Matthew Hooker 2017-03-28 18:06:50 -07:00
parent d1b20b3d9c
commit 0149f679de
No known key found for this signature in database
GPG Key ID: 7B5F933D9CE8C6A1
6 changed files with 9 additions and 8 deletions

View File

@ -25,7 +25,7 @@ func (s *StepCreateEncryptedAMICopy) Run(state multistep.StateBag) multistep.Ste
// Encrypt boot not set, so skip step
if !s.EncryptBootVolume {
if kmsKeyId != "" {
log.Printf(fmt.Sprintf("Ignoring KMS Key ID: %s, encrypted=false", kmsKeyId))
log.Printf("Ignoring KMS Key ID: %s, encrypted=false", kmsKeyId)
}
return multistep.ActionContinue
}

View File

@ -2,11 +2,12 @@ package qemu
import (
"fmt"
"github.com/mitchellh/multistep"
"github.com/mitchellh/packer/packer"
"log"
"math/rand"
"net"
"github.com/mitchellh/multistep"
"github.com/mitchellh/packer/packer"
)
// This step configures the VM to enable the VNC server.
@ -28,7 +29,7 @@ func (stepConfigureVNC) Run(state multistep.StateBag) multistep.StepAction {
// best.
msg := fmt.Sprintf("Looking for available port between %d and %d on %s", config.VNCPortMin, config.VNCPortMax, config.VNCBindAddress)
ui.Say(msg)
log.Printf(msg)
log.Print(msg)
var vncPort uint
portRange := int(config.VNCPortMax - config.VNCPortMin)
for {

View File

@ -317,7 +317,7 @@ func (p *Provisioner) retryable(f func() error) error {
// Create an error and log it
err = fmt.Errorf("Retryable error: %s", err)
log.Printf(err.Error())
log.Print(err.Error())
// Check if we timed out, otherwise we retry. It is safe to
// retry since the only error case above is if the command

View File

@ -348,7 +348,7 @@ func (p *Provisioner) retryable(f func() error) error {
// Create an error and log it
err = fmt.Errorf("Retryable error: %s", err)
log.Printf(err.Error())
log.Print(err.Error())
// Check if we timed out, otherwise we retry. It is safe to
// retry since the only error case above is if the command

View File

@ -217,7 +217,7 @@ func (p *Provisioner) retryable(f func() error) error {
// Create an error and log it
err = fmt.Errorf("Retryable error: %s", err)
log.Printf(err.Error())
log.Print(err.Error())
// Check if we timed out, otherwise we retry. It is safe to
// retry since the only error case above is if the command

View File

@ -270,7 +270,7 @@ func (p *Provisioner) retryable(f func() error) error {
// Create an error and log it
err = fmt.Errorf("Retryable error: %s", err)
log.Printf(err.Error())
log.Print(err.Error())
// Check if we timed out, otherwise we retry. It is safe to
// retry since the only error case above is if the command