Sfoglia il codice sorgente

fix mkdir error code. (#7944)

geniusgogo 2 anni fa
parent
commit
1b5ed06d38
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      components/dfs/dfs_v2/src/dfs_posix.c

+ 1 - 1
components/dfs/dfs_v2/src/dfs_posix.c

@@ -676,7 +676,7 @@ int mkdir(const char *path, mode_t mode)
 
     if (path && dfs_file_lstat(path, &stat) == 0)
     {
-        rt_set_errno(-RT_ERROR);
+        rt_set_errno(-EEXIST);
         return -1;
     }