Merge "Use FUSE_COMPAT_22_INIT_OUT_SIZE always as the resopnse size of FUSE_INIT." am: 0673412bb9 am: 357876455c am: 5f7ed2dd60
am: 2b73980091
Change-Id: Ibad52be01df7077ce06b86c15c7bb4ad44be1408
diff --git a/sdcard/fuse.cpp b/sdcard/fuse.cpp
index 28b191a..95559d7 100644
--- a/sdcard/fuse.cpp
+++ b/sdcard/fuse.cpp
@@ -1260,12 +1260,9 @@
#if defined(FUSE_COMPAT_22_INIT_OUT_SIZE)
/* FUSE_KERNEL_VERSION >= 23. */
- /* If the kernel only works on minor revs older than or equal to 22,
- * then use the older structure size since this code only uses the 7.22
- * version of the structure. */
- if (req->minor <= 22) {
- fuse_struct_size = FUSE_COMPAT_22_INIT_OUT_SIZE;
- }
+ /* Since we return minor version 15, the kernel does not accept the latest
+ * fuse_init_out size. We need to use FUSE_COMPAT_22_INIT_OUT_SIZE always.*/
+ fuse_struct_size = FUSE_COMPAT_22_INIT_OUT_SIZE;
#endif
out.major = FUSE_KERNEL_VERSION;