summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.sbin/dhcp/server/dhcp.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/usr.sbin/dhcp/server/dhcp.c b/usr.sbin/dhcp/server/dhcp.c
index a50be1bce01..6dc9f5e185a 100644
--- a/usr.sbin/dhcp/server/dhcp.c
+++ b/usr.sbin/dhcp/server/dhcp.c
@@ -42,7 +42,7 @@
#ifndef lint
static char copyright[] =
-"$Id: dhcp.c,v 1.4 2001/04/10 22:47:37 chris Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
+"$Id: dhcp.c,v 1.5 2001/04/25 11:40:11 deraadt Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
@@ -563,6 +563,12 @@ void ack_lease (packet, lease, offer, when)
struct class *vendor_class, *user_class;
int i;
+ /* If we're already acking this lease, don't do it again. */
+ if (lease -> state) {
+ note ("already acking lease %s", piaddr (lease -> ip_addr));
+ return;
+ }
+
if (packet -> options [DHO_DHCP_CLASS_IDENTIFIER].len) {
vendor_class =
find_class (0,