From 2a57ba9f966d43639b5e485c1d939552ae3e5a7b Mon Sep 17 00:00:00 2001 From: shaojinchun Date: Thu, 22 Nov 2018 18:21:45 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=9F=E4=B8=80getcwd=E5=92=8Cchdir=E7=9A=84?= =?UTF-8?q?=E5=8A=A0=E9=94=81=E6=96=B9=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/dfs/src/dfs_posix.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/dfs/src/dfs_posix.c b/components/dfs/src/dfs_posix.c index 97531ad59c..f47a60ee5d 100644 --- a/components/dfs/src/dfs_posix.c +++ b/components/dfs/src/dfs_posix.c @@ -890,9 +890,9 @@ int access(const char *path, int amode) char *getcwd(char *buf, size_t size) { #ifdef DFS_USING_WORKDIR - rt_enter_critical(); + dfs_lock(); strncpy(buf, working_directory, size); - rt_exit_critical(); + dfs_unlock(); #else rt_kprintf(NO_WORKING_DIR); #endif -- GitLab