Browse Source

Fixed compilation warning about wrong type

It fixes the following warnings:

  agent/config/builder.go:1201: Errorf format %q has arg s of wrong type *string
  agent/config/builder.go:1240: Errorf format %q has arg s of wrong type *string
pull/4365/head
Pierre Souchay 6 years ago
parent
commit
b112bdd52d
  1. 4
      agent/config/builder.go

4
agent/config/builder.go

@ -1198,7 +1198,7 @@ func (b *Builder) expandAddrs(name string, s *string) []net.Addr {
x, err := template.Parse(*s)
if err != nil {
b.err = multierror.Append(b.err, fmt.Errorf("%s: error parsing %q: %s", name, s, err))
b.err = multierror.Append(b.err, fmt.Errorf("%s: error parsing %s: %s", name, *s, err))
return nil
}
@ -1237,7 +1237,7 @@ func (b *Builder) expandOptionalAddrs(name string, s *string) []string {
x, err := template.Parse(*s)
if err != nil {
b.err = multierror.Append(b.err, fmt.Errorf("%s: error parsing %q: %s", name, s, err))
b.err = multierror.Append(b.err, fmt.Errorf("%s: error parsing %s: %s", name, *s, err))
return nil
}

Loading…
Cancel
Save