diff options
author | Howard Zhang <howard.zhang@arm.com> | 2020-10-30 18:26:44 +0800 |
---|---|---|
committer | Howard Zhang <howard.zhang@arm.com> | 2020-11-03 10:35:28 +0800 |
commit | b6a5204c51a4c134f587d358a54fe8d3fb33fc2d (patch) | |
tree | ec381ed6f4a3f5d89f76bafdf4722d1e53d5eb16 /test/fuse | |
parent | 34a6e9576a9684087f95f57ee73171a637bee8b2 (diff) |
ARM64:fuse:alian stat struct order on multiarch
fields order in stat struct is different from
x86 to arm64. Please refer to
x86_64-linux-gnu/bits/stat.h
aarch64-linux-gnu/bits/stat.h
Signed-off-by: Howard Zhang <howard.zhang@arm.com>
Diffstat (limited to 'test/fuse')
-rw-r--r-- | test/fuse/linux/stat_test.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/fuse/linux/stat_test.cc b/test/fuse/linux/stat_test.cc index 6f032cac1..73321592b 100644 --- a/test/fuse/linux/stat_test.cc +++ b/test/fuse/linux/stat_test.cc @@ -76,8 +76,13 @@ TEST_F(StatTest, StatNormal) { // Check filesystem operation result. struct stat expected_stat = { .st_ino = attr.ino, +#ifdef __aarch64__ + .st_mode = expected_mode, + .st_nlink = attr.nlink, +#else .st_nlink = attr.nlink, .st_mode = expected_mode, +#endif .st_uid = attr.uid, .st_gid = attr.gid, .st_rdev = attr.rdev, @@ -152,8 +157,13 @@ TEST_F(StatTest, FstatNormal) { // Check filesystem operation result. struct stat expected_stat = { .st_ino = attr.ino, +#ifdef __aarch64__ + .st_mode = expected_mode, + .st_nlink = attr.nlink, +#else .st_nlink = attr.nlink, .st_mode = expected_mode, +#endif .st_uid = attr.uid, .st_gid = attr.gid, .st_rdev = attr.rdev, |