Skip to content

Commit

Permalink
Update.
Browse files Browse the repository at this point in the history
1999-04-16  Ulrich Drepper  <drepper@cygnus.com>

	* nscd/cache.c (prune_cache): Only disable file checking for
	future if the file does not exist.
	Update file_mtime if cache was flushed.
  • Loading branch information
Ulrich Drepper committed Apr 16, 1999
1 parent 3d08d80 commit 2456406
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
6 changes: 6 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
1999-04-16 Ulrich Drepper <drepper@cygnus.com>

* nscd/cache.c (prune_cache): Only disable file checking for
future if the file does not exist.
Update file_mtime if cache was flushed.

1999-04-15 David S. Miller <davem@redhat.com>

* sysdeps/sparc/sparc32/strcat.S: Avoid using register g6.
Expand Down
8 changes: 5 additions & 3 deletions nscd/cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,18 +142,20 @@ prune_cache (struct database *table, time_t now)
if (stat (table->filename, &st) < 0)
{
char buf[128];
/* We cannot stat() the file, disable file checking. */
/* We cannot stat() the file, disable file checking if the
file does not exist. */
dbg_log (_("cannot stat() file `%s': %s"),
table->filename, strerror_r (errno, buf, sizeof (buf)));
table->check_file = 0;
if (errno == ENOENT)
table->check_file = 0;
}
else
{
if (st.st_mtime != table->file_mtime)
{
/* The file changed. Invalidate all entries. */
now = LONG_MAX;
st.st_mtime = table->file_mtime;
table->file_mtime = st.st_mtime;
}
}
}
Expand Down

0 comments on commit 2456406

Please sign in to comment.