diff --git a/components/dfs/filesystems/elmfat/dfs_elm.c b/components/dfs/filesystems/elmfat/dfs_elm.c index a385295ec3..cad548b6b5 100644 --- a/components/dfs/filesystems/elmfat/dfs_elm.c +++ b/components/dfs/filesystems/elmfat/dfs_elm.c @@ -780,11 +780,9 @@ DRESULT disk_ioctl(BYTE drv, BYTE ctrl, void *buff) rt_device_control(device, RT_DEVICE_CTRL_BLK_GETGEOME, &geometry); *(DWORD *)buff = geometry.block_size/geometry.bytes_per_sector; - } - else if (ctrl == CTRL_SYNC) - { - rt_device_control(device, RT_DEVICE_CTRL_BLK_SYNC, RT_NULL); } + else if (ctrl == CTRL_SYNC) + rt_device_control(device, RT_DEVICE_CTRL_BLK_SYNC, RT_NULL); return RES_OK; }