mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-13 21:44:16 +00:00
Remove file_access_attempt_t::stale
It was unused.
This commit is contained in:
parent
76306c4582
commit
6dd2766a15
2 changed files with 1 additions and 4 deletions
|
@ -26,7 +26,6 @@
|
|||
static const int kAutoloadStalenessInterval = 15;
|
||||
|
||||
file_access_attempt_t access_file(const wcstring &path, int mode) {
|
||||
// std::fwprintf(stderr, L"Touch %ls\n", path.c_str());
|
||||
file_access_attempt_t result = {};
|
||||
struct stat statbuf;
|
||||
if (wstat(path, &statbuf)) {
|
||||
|
@ -42,7 +41,6 @@ file_access_attempt_t access_file(const wcstring &path, int mode) {
|
|||
|
||||
// Note that we record the last checked time after the call, on the assumption that in a slow
|
||||
// filesystem, the lag comes before the kernel check, not after.
|
||||
result.stale = false;
|
||||
result.last_checked = time(NULL);
|
||||
return result;
|
||||
}
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
#include "common.h"
|
||||
#include "env.h"
|
||||
#include "lru.h"
|
||||
#include "wutil.h"
|
||||
|
||||
/// Record of an attempt to access a file.
|
||||
struct file_access_attempt_t {
|
||||
|
@ -20,8 +21,6 @@ struct file_access_attempt_t {
|
|||
time_t last_checked;
|
||||
/// Whether or not we believe we can access this file
|
||||
bool accessible;
|
||||
/// The access attempt is stale
|
||||
bool stale;
|
||||
/// If we cannot access the file, the error code encountered.
|
||||
int error;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue