diff options
author | Dario Maiocchi <dmaiocchi@suse.com> | 2017-11-10 19:42:09 +0100 |
---|---|---|
committer | Dario Maiocchi <dmaiocchi@suse.com> | 2017-11-16 11:26:28 +0100 |
commit | 2e1a19e5d457d8dd75f20e9b6ca19bde9a628a8d (patch) | |
tree | b656022f8fe74a06c4ddc28aa1816783a265c0ba /libvirt/qemu_agent.go | |
parent | 56e399a1db9a371f2730f7ebf7513a3a544e0530 (diff) | |
download | terraform-provider-libvirt-2e1a19e5d457d8dd75f20e9b6ca19bde9a628a8d.tar terraform-provider-libvirt-2e1a19e5d457d8dd75f20e9b6ca19bde9a628a8d.tar.gz |
Fix IP golint issues (style)
Diffstat (limited to 'libvirt/qemu_agent.go')
-rw-r--r-- | libvirt/qemu_agent.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libvirt/qemu_agent.go b/libvirt/qemu_agent.go index 656a1261..d89866a3 100644 --- a/libvirt/qemu_agent.go +++ b/libvirt/qemu_agent.go @@ -7,18 +7,18 @@ import ( libvirt "github.com/libvirt/libvirt-go" ) - +// QemuAgentInterfacesResponse type type QemuAgentInterfacesResponse struct { Interfaces []QemuAgentInterface `json:"return"` } - +// QemuAgentInterface type type QemuAgentInterface struct { Name string `json:"name"` Hwaddr string `json:"hardware-address"` - IpAddresses []QemuAgentInterfaceIpAddress `json:"ip-addresses"` + IPAddresses []QemuAgentInterfaceIPAddress `json:"ip-addresses"` } - -type QemuAgentInterfaceIpAddress struct { +// QemuAgentInterfaceIPAddress type +type QemuAgentInterfaceIPAddress struct { Type string `json:"ip-address-type"` Address string `json:"ip-address"` Prefix uint `json:"prefix"` @@ -64,7 +64,7 @@ func getDomainInterfacesViaQemuAgent(domain LibVirtDomain, wait4ipv4 bool) []lib Hwaddr: iface.Hwaddr} ipv4Assigned := false - for _, addr := range iface.IpAddresses { + for _, addr := range iface.IPAddresses { if addr.Address == "" { // ignore interfaces without an address (eg. waiting for dhcp lease) continue |