#ifndef lint
static char copyright[] =
-"$Id: confpars.c,v 1.77 1999/09/08 01:49:56 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
+"$Id: confpars.c,v 1.78 1999/09/09 21:11:21 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
token = next_token (&val, cfile);
if (token == EOF)
break;
- if (token != LEASE) {
- log_error ("Corrupt lease file - possible data loss!");
- skip_to_semi (cfile);
- } else {
+ if (token == LEASE) {
struct lease *lease;
lease = parse_lease_declaration (cfile);
if (lease)
enter_lease (lease);
else
parse_warn ("possibly corrupt lease file");
+ } else if (token == HOST) {
+ parse_host_declaration (cfile, &root_group);
+ } else {
+ log_error ("Corrupt lease file - possible data loss!");
+ skip_to_semi (cfile);
}
} while (1);
declaration);
} while (1);
- enter_host (host, dynamicp);
+ enter_host (host, dynamicp, 0);
}
/* class-declaration :== STRING LBRACE parameters declarations RBRACE
#ifndef lint
static char ocopyright[] =
-"$Id: dhcpd.c,v 1.72 1999/09/08 01:50:19 mellon Exp $ Copyright 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium.";
+"$Id: dhcpd.c,v 1.73 1999/09/09 21:11:27 mellon Exp $ Copyright 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium.";
#endif
static char copyright[] =
/* Set up the client classification system. */
classification_setup ();
+ /* Initialize the omapi system. */
+ status = omapi_init ();
+ if (status != ISC_R_SUCCESS)
+ log_fatal ("Can't initialize OMAPI: %s\n",
+ isc_result_totext (status));
+
+ /* Set up the OMAPI wrappers for various server database internal
+ objects. */
+ dhcp_db_objects_setup ();
+
/* Read the dhcpd.conf file... */
if (!readconf ())
log_fatal ("Configuration file errors encountered -- exiting");
OMAPI_PROTOCOL_PORT, 1);
if (status != ISC_R_SUCCESS)
log_fatal ("Can't start OMAPI protocol: %s",
- isc_result_totext (result));
-
- /* Set up the OMAPI wrappers for various server database internal
- objects. */
- dhcp_db_objects_setup ();
+ isc_result_totext (status));
#ifndef DEBUG
if (daemon) {