summaryrefslogtreecommitdiffhomepage
path: root/dhcpv4/bsdp/client.go
diff options
context:
space:
mode:
authorinsomniac <insomniacslk@users.noreply.github.com>2018-07-27 15:39:11 +0100
committerGitHub <noreply@github.com>2018-07-27 15:39:11 +0100
commit46ce21cd90de7e082c7ef2eaefb6e499fa80fb3a (patch)
tree97bbf0af2a89e3107de600da77bedced37a857d1 /dhcpv4/bsdp/client.go
parent45ecdd89ec87e6c8d4833d987ef94cab25c064c5 (diff)
[DHCPv4] BroadcastSendReceive now can wait for specific reply types (#95)
Diffstat (limited to 'dhcpv4/bsdp/client.go')
-rw-r--r--dhcpv4/bsdp/client.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/dhcpv4/bsdp/client.go b/dhcpv4/bsdp/client.go
index 10cf6b4..3d885aa 100644
--- a/dhcpv4/bsdp/client.go
+++ b/dhcpv4/bsdp/client.go
@@ -60,7 +60,7 @@ func (c *Client) Exchange(ifname string, informList *dhcpv4.DHCPv4) ([]dhcpv4.DH
conversation[0] = *informList
// ACK[LIST]
- ackForList, err := dhcpv4.BroadcastSendReceive(sendFd, recvFd, informList, c.ReadTimeout, c.WriteTimeout)
+ ackForList, err := dhcpv4.BroadcastSendReceive(sendFd, recvFd, informList, c.ReadTimeout, c.WriteTimeout, dhcpv4.MessageTypeAck)
if err != nil {
return conversation, err
}
@@ -86,7 +86,7 @@ func (c *Client) Exchange(ifname string, informList *dhcpv4.DHCPv4) ([]dhcpv4.DH
conversation = append(conversation, *informSelect)
// ACK[SELECT]
- ackForSelect, err := dhcpv4.BroadcastSendReceive(sendFd, recvFd, informSelect, c.ReadTimeout, c.WriteTimeout)
+ ackForSelect, err := dhcpv4.BroadcastSendReceive(sendFd, recvFd, informSelect, c.ReadTimeout, c.WriteTimeout, dhcpv4.MessageTypeAck)
castVendorOpt(ackForSelect)
if err != nil {
return conversation, err