mirror of
https://github.com/trapexit/mergerfs.git
synced 2025-02-25 16:44:35 +08:00
Merge pull request #878 from trapexit/readdir_rewind_fix
reset dentry buffer when rewind'ed
This commit is contained in:
commit
39d98f1eac
@ -65,6 +65,8 @@ namespace l
|
|||||||
uint64_t namelen;
|
uint64_t namelen;
|
||||||
struct linux_dirent64 *d;
|
struct linux_dirent64 *d;
|
||||||
|
|
||||||
|
fuse_dirents_reset(buf_);
|
||||||
|
|
||||||
buf = (char*)g_DENTS_BUF_POOL.alloc();
|
buf = (char*)g_DENTS_BUF_POOL.alloc();
|
||||||
if(buf == NULL)
|
if(buf == NULL)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
@ -70,6 +70,8 @@ namespace l
|
|||||||
fuse_entry_t entry;
|
fuse_entry_t entry;
|
||||||
struct linux_dirent64 *d;
|
struct linux_dirent64 *d;
|
||||||
|
|
||||||
|
fuse_dirents_reset(buf_);
|
||||||
|
|
||||||
buf = (char*)g_DENTS_BUF_POOL.alloc();
|
buf = (char*)g_DENTS_BUF_POOL.alloc();
|
||||||
|
|
||||||
entry.nodeid = 0;
|
entry.nodeid = 0;
|
||||||
|
@ -71,6 +71,8 @@ namespace l
|
|||||||
uint64_t namelen;
|
uint64_t namelen;
|
||||||
fuse_entry_t entry;
|
fuse_entry_t entry;
|
||||||
|
|
||||||
|
fuse_dirents_reset(buf_);
|
||||||
|
|
||||||
entry.nodeid = 0;
|
entry.nodeid = 0;
|
||||||
entry.generation = 0;
|
entry.generation = 0;
|
||||||
entry.entry_valid = entry_timeout_;
|
entry.entry_valid = entry_timeout_;
|
||||||
|
@ -67,6 +67,8 @@ namespace l
|
|||||||
string fullpath;
|
string fullpath;
|
||||||
uint64_t namelen;
|
uint64_t namelen;
|
||||||
|
|
||||||
|
fuse_dirents_reset(buf_);
|
||||||
|
|
||||||
for(const auto &branch : *branches_)
|
for(const auto &branch : *branches_)
|
||||||
{
|
{
|
||||||
int rv;
|
int rv;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user