aboutsummaryrefslogtreecommitdiff
path: root/nuttx/fs/fat/fs_fat32.c
diff options
context:
space:
mode:
Diffstat (limited to 'nuttx/fs/fat/fs_fat32.c')
-rw-r--r--nuttx/fs/fat/fs_fat32.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/nuttx/fs/fat/fs_fat32.c b/nuttx/fs/fat/fs_fat32.c
index c10c28a5c..df8962b51 100644
--- a/nuttx/fs/fat/fs_fat32.c
+++ b/nuttx/fs/fat/fs_fat32.c
@@ -381,6 +381,7 @@ static int fat_close(FAR struct file *filep)
{
struct inode *inode;
struct fat_file_s *ff;
+ struct fat_mountpt_s *fs;
int ret = OK;
/* Sanity checks */
@@ -391,6 +392,7 @@ static int fat_close(FAR struct file *filep)
ff = filep->f_priv;
inode = filep->f_inode;
+ fs = inode->i_private;
/* Do not check if the mount is healthy. We must support closing of
* the file even when there is healthy mount.
@@ -408,6 +410,7 @@ static int fat_close(FAR struct file *filep)
if (ff->ff_buffer)
{
+ (void)fs; /* Unused if fat_io_free == free(). */
fat_io_free(ff->ff_buffer, fs->fs_hwsectorsize);
}