refactor
All checks were successful
BlockStorage/repertory_osx_builds/pipeline/head This commit looks good
BlockStorage/repertory_linux_builds/pipeline/head This commit looks good

This commit is contained in:
2023-12-10 16:21:01 -06:00
parent 0af9c6e8b0
commit 7fe7299e7c
2 changed files with 15 additions and 12 deletions

View File

@@ -304,11 +304,11 @@ void fuse_drive_base::populate_stat(const std::string &api_path,
const api_meta_map &meta, bool directory,
i_provider &provider, struct stat *st) {
memset(st, 0, sizeof(struct stat));
st->st_nlink =
(directory ? 2 + (size_or_count == 0U
? provider.get_directory_item_count(api_path)
: size_or_count)
: 1);
st->st_nlink = static_cast<nlink_t>(
directory ? 2 + (size_or_count == 0U
? provider.get_directory_item_count(api_path)
: size_or_count)
: 1);
if (directory) {
st->st_blocks = 0;
} else {