fs/fat: Handle the tail '/' correctly

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I72c4d018c174d094d777941d0679ad792a1f5527
This commit is contained in:
Xiang Xiao 2020-09-22 14:44:41 +08:00 committed by Abdelatif Guettouche
parent 5ffb1c6a0b
commit 8567637378

View File

@ -2656,6 +2656,11 @@ int fat_finddirentry(FAR struct fat_mountpt_s *fs,
return -ENOTDIR;
}
if (*path == '\0')
{
return OK;
}
/* Get the cluster number of this directory */
cluster =