git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2292 bbd45198-f89e-11dd-88c7-29a3b14d5316
@@ -309,6 +309,9 @@ int dfs_elm_open(struct dfs_fd *file)
fd = (FIL *)rt_malloc(sizeof(FIL));
if (fd == RT_NULL)
{
+#if _VOLUMES > 1
+ rt_free(drivers_fn);
+#endif
return -DFS_STATUS_ENOMEM;
}