1
0
Fork 0
forked from nuttx/nuttx-update

fs: flashback to release all file descriptors in group to increase debugging time.

Change-Id: I47851f7e679addf36077c491ef7d1a5a29d1c2be
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
This commit is contained in:
dongjiuzhu 2020-10-15 17:56:03 +08:00 committed by Xiang Xiao
parent a396b191d4
commit c22ab31728

View file

@ -150,9 +150,9 @@ void files_releaselist(FAR struct filelist *list)
* because there should not be any references in this context.
*/
for (i = 0; i < CONFIG_NFILE_DESCRIPTORS; i++)
for (i = CONFIG_NFILE_DESCRIPTORS; i > 0; i--)
{
_files_close(&list->fl_files[i]);
_files_close(&list->fl_files[i - 1]);
}
/* Destroy the semaphore */