The LibCephFS.DirLs test calls ceph_readdirplus_r and expects
the returning dirent.d_ino value to match the ceph_statx.stx_ino
inode.
The issue is that on Windows, "dirent" uses long (4B) inodes, which
isn't large enough to hold the ceph inodes (uint64_t).
For now, we'll drop this specific assertion. On Windows, the
ceph_statx inode should be used instead of the dirent one.
Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
sscanf(name, "dirf%d", &size);
ASSERT_TRUE(stx.stx_mask & CEPH_STATX_SIZE);
ASSERT_EQ(stx.stx_size, (size_t)size);
+ // On Windows, dirent uses long (4B) inodes, which get trimmed
+ // and can't be used.
+ // TODO: consider defining ceph_dirent.
+ #ifndef _WIN32
ASSERT_EQ(stx.stx_ino, rdent.d_ino);
+ #endif
//ASSERT_EQ(st.st_mode, (mode_t)0666);
}
ASSERT_EQ(found, entries);