mirror of
git://git.code.sf.net/p/dhcpd-pools/code
synced 2025-12-16 15:57:00 +00:00
getdata: remove POSIX_FADV_NOREUSE
It is too difficult to know what users might want to do. Maybe some run this software all the time from a monitoring system, and in cases like that it is best to have caches helping. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
parent
344e01c1f6
commit
2b75a0d78e
1 changed files with 0 additions and 8 deletions
|
|
@ -71,10 +71,6 @@ int parse_leases(void)
|
|||
if (dhcpd_leases == NULL)
|
||||
error(EXIT_FAILURE, errno, "parse_leases: %s", config.dhcpdlease_file);
|
||||
#ifdef HAVE_POSIX_FADVISE
|
||||
# ifdef POSIX_FADV_NOREUSE
|
||||
if (posix_fadvise(fileno(dhcpd_leases), 0, 0, POSIX_FADV_NOREUSE) != 0)
|
||||
error(EXIT_FAILURE, errno, "parse_leases: fadvise %s", config.dhcpdlease_file);
|
||||
# endif /* POSIX_FADV_NOREUSE */
|
||||
# ifdef POSIX_FADV_SEQUENTIAL
|
||||
if (posix_fadvise(fileno(dhcpd_leases), 0, 0, POSIX_FADV_SEQUENTIAL) != 0)
|
||||
error(EXIT_FAILURE, errno, "parse_leases: fadvise %s", config.dhcpdlease_file);
|
||||
|
|
@ -200,10 +196,6 @@ void parse_config(int is_include, const char *restrict config_file,
|
|||
if (dhcpd_config == NULL)
|
||||
error(EXIT_FAILURE, errno, "parse_config: %s", config_file);
|
||||
#ifdef HAVE_POSIX_FADVISE
|
||||
# ifdef POSIX_FADV_NOREUSE
|
||||
if (posix_fadvise(fileno(dhcpd_config), 0, 0, POSIX_FADV_NOREUSE) != 0)
|
||||
error(EXIT_FAILURE, errno, "parse_config: fadvise %s", config_file);
|
||||
# endif /* POSIX_FADV_NOREUSE */
|
||||
# ifdef POSIX_FADV_SEQUENTIAL
|
||||
if (posix_fadvise(fileno(dhcpd_config), 0, 0, POSIX_FADV_SEQUENTIAL) != 0)
|
||||
error(EXIT_FAILURE, errno, "parse_config: fadvise %s", config_file);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue