!947 fix: 使用LOSCFG_FS_FREE_HOOK释放内存

Merge pull request !947 from Hongjin Li/max_open_dirs
This commit is contained in:
openharmony_ci 2022-12-01 02:50:03 +00:00 committed by Gitee
commit 9e4978f57f
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 1 additions and 1 deletions

View File

@ -670,7 +670,7 @@ static DIR *VfsOpendir(const char *path)
if (g_dirNum >= LOSCFG_MAX_OPEN_DIRS) {
VFS_ERRNO_SET(ENFILE);
VfsUnlock();
free(dir);
LOSCFG_FS_FREE_HOOK(dir);
return NULL;
}