]> git.ipfire.org Git - thirdparty/dhcp.git/commitdiff
- Open the database file for appending before expiring pools, in case leases
authorTed Lemon <source@isc.org>
Sun, 7 Nov 1999 20:28:23 +0000 (20:28 +0000)
committerTed Lemon <source@isc.org>
Sun, 7 Nov 1999 20:28:23 +0000 (20:28 +0000)
  need to be rewritten during the expirating process.

server/db.c

index 261146c6f5062c445116c2bdc0030925c8299fa8..d24b08297396de4ba7b6204d8f3ea306af0e7fb0 100644 (file)
@@ -22,7 +22,7 @@
 
 #ifndef lint
 static char copyright[] =
-"$Id: db.c,v 1.36 1999/10/28 13:02:24 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
+"$Id: db.c,v 1.37 1999/11/07 20:28:23 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
 #endif /* not lint */
 
 #include "dhcpd.h"
@@ -503,6 +503,7 @@ void db_startup (testp)
        read_leases ();
 
        if (!testp) {
+               db_file = fopen (path_dhcpd_db, "a");
                expire_all_pools ();
                GET_TIME (&write_time);
                new_lease_file ();