diff options
author | Julio Merino <jmmv@google.com> | 2016-02-08 11:43:01 -0500 |
---|---|---|
committer | Julio Merino <jmmv@meroh.net> | 2016-02-08 20:50:22 -0500 |
commit | d8230e72ca01fd27509ef7134f0957c73f164ae3 (patch) | |
tree | 2dac21fc3dc0ab2dd2103350d08e560177c634a5 /sshfs.c | |
parent | e0025219b33de3cbf3152884b48412feb461c894 (diff) | |
download | sshfs-d8230e72ca01fd27509ef7134f0957c73f164ae3.tar sshfs-d8230e72ca01fd27509ef7134f0957c73f164ae3.tar.gz sshfs-d8230e72ca01fd27509ef7134f0957c73f164ae3.tar.bz2 sshfs-d8230e72ca01fd27509ef7134f0957c73f164ae3.zip |
Drop the cache_enabled hack
cache_enabled leaked the cache.on setting from the cache module abstraction
back into sshfs, and it only did so for the Darwin case.
This hack was being used to avoid calling cache_add_attr and cache_invalidate
when the cache was disabled... but these two functions already do nothing when
in that case: there is no need to do a second check in the caller.
Diffstat (limited to 'sshfs.c')
-rw-r--r-- | sshfs.c | 10 |
1 files changed, 0 insertions, 10 deletions
@@ -2591,21 +2591,11 @@ static int sshfs_open_common(const char *path, mode_t mode, } if (!err) { -#ifdef __APPLE__ - if (cache_enabled) - cache_add_attr(path, &stbuf, wrctr); -#else cache_add_attr(path, &stbuf, wrctr); -#endif buf_finish(&sf->handle); fi->fh = (unsigned long) sf; } else { -#ifdef __APPLE__ - if (cache_enabled) - cache_invalidate(path); -#else cache_invalidate(path); -#endif g_free(sf); } buf_free(&buf); |