From 8ad000e9a706c208bdcdaaddc32aea9908be1a7c Mon Sep 17 00:00:00 2001 From: wangchen <253227059@qq.com> Date: Mon, 21 Nov 2022 13:16:53 +0000 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=A0=BC=E5=BC=8F=E5=8C=96=E6=9C=AAunmo?= =?UTF-8?q?unt=E7=9B=AE=E5=BD=95=E5=88=A4=E6=96=AD=E5=A4=B1=E6=95=88=20?= =?UTF-8?q?=E3=80=90=E8=83=8C=E6=99=AF=E3=80=91=E6=A0=BC=E5=BC=8F=E5=8C=96?= =?UTF-8?q?=E6=9C=AAunmount=E7=9B=AE=E5=BD=95=E5=88=A4=E6=96=AD=E5=A4=B1?= =?UTF-8?q?=E6=95=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【修改方案】 1, 修改判断format逻辑 【影响】 对现有的产品编译不会有影响。 re #I62BMF Signed-off-by: wangchen --- components/fs/vfs/vfs_partition.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/fs/vfs/vfs_partition.c b/components/fs/vfs/vfs_partition.c index c4c818f7..ceaef903 100644 --- a/components/fs/vfs/vfs_partition.c +++ b/components/fs/vfs/vfs_partition.c @@ -160,7 +160,7 @@ int LOS_PartitionFormat(const char *partName, char *fsType, void *data) format is not allowed when the device has been mounted. */ struct MountPoint *iter = NULL; LOS_MP_FOR_EACH_ENTRY(iter) { - if ((iter->mPath != NULL) && (strcmp(iter->mPath, partName) == 0)) { + if ((iter->mDev != NULL) && (strcmp(iter->mDev, partName) == 0)) { errno = EBUSY; return (int)LOS_NOK; } -- Gitee