mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-12-04 13:50:07 -05:00
Misc cleanup
This commit is contained in:
parent
a5a6c892b9
commit
a0cff637e1
19 changed files with 272 additions and 446 deletions
|
|
@ -20,6 +20,9 @@
|
|||
/* 32KB - same as glibc getdents buffer size */
|
||||
#define DENTS_BUF_EXPAND_SIZE (1024 * 32)
|
||||
|
||||
/* Initial pre-allocated capacity for directory-entry offset vector */
|
||||
#define DENTS_OFFS_INITIAL_CAPACITY 64
|
||||
|
||||
static
|
||||
uint64_t
|
||||
_round_up(const uint64_t number_,
|
||||
|
|
@ -146,7 +149,7 @@ fuse_dirents_init(fuse_dirents_t *d_)
|
|||
return -ENOMEM;
|
||||
|
||||
kv_init(d_->offs);
|
||||
kv_resize(uint32_t,d_->offs,64);
|
||||
kv_resize(uint32_t,d_->offs,DENTS_OFFS_INITIAL_CAPACITY);
|
||||
kv_push(uint32_t,d_->offs,0);
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue