summaryrefslogtreecommitdiff
path: root/contrib/lease-tools/dhcp_release6.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/lease-tools/dhcp_release6.c')
-rw-r--r--contrib/lease-tools/dhcp_release6.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/contrib/lease-tools/dhcp_release6.c b/contrib/lease-tools/dhcp_release6.c
index 7f79fa7..d680222 100644
--- a/contrib/lease-tools/dhcp_release6.c
+++ b/contrib/lease-tools/dhcp_release6.c
@@ -376,9 +376,12 @@ int send_release_packet(const char* iface, struct dhcp6_packet* packet)
sleep(1);
continue;
}
+
+ close(sock);
return result;
}
-
+
+ close(sock);
fprintf(stderr, "Response timed out\n");
return -1;
}