mirror of
https://gitlab.isc.org/isc-projects/dhcp
synced 2025-08-29 21:38:10 +00:00
Don't try to parse the lease file if it's not there
This commit is contained in:
parent
9c238be64c
commit
8e3de495cb
@ -81,8 +81,10 @@ void read_leases (void)
|
||||
jmp_buf bc;
|
||||
|
||||
/* Open the lease file... */
|
||||
if ((cfile = fopen (_PATH_DHCPD_DB, "r")) == NULL)
|
||||
if ((cfile = fopen (_PATH_DHCPD_DB, "r")) == NULL) {
|
||||
warn ("Can't open lease database %s: %m", _PATH_DHCPD_DB);
|
||||
return;
|
||||
}
|
||||
do {
|
||||
token = next_token (&val, cfile);
|
||||
if (token == EOF)
|
||||
|
@ -81,8 +81,10 @@ void read_leases (void)
|
||||
jmp_buf bc;
|
||||
|
||||
/* Open the lease file... */
|
||||
if ((cfile = fopen (_PATH_DHCPD_DB, "r")) == NULL)
|
||||
if ((cfile = fopen (_PATH_DHCPD_DB, "r")) == NULL) {
|
||||
warn ("Can't open lease database %s: %m", _PATH_DHCPD_DB);
|
||||
return;
|
||||
}
|
||||
do {
|
||||
token = next_token (&val, cfile);
|
||||
if (token == EOF)
|
||||
|
Loading…
x
Reference in New Issue
Block a user