diff --git a/components/dfs/filesystems/nfs/dfs_nfs.c b/components/dfs/filesystems/nfs/dfs_nfs.c index 3709cc33feb3130eafc48f0c728b7b82b23853e3..0f40fa4292bd2fbee68316eec8a6fae5c507103f 100644 --- a/components/dfs/filesystems/nfs/dfs_nfs.c +++ b/components/dfs/filesystems/nfs/dfs_nfs.c @@ -233,7 +233,7 @@ static nfs_fh3 *get_dir_handle(struct nfs_filesystem *nfs, const char *name) copy_handle(handle, &nfs->current_handle); } - while ((file = strtok_r(RT_NULL, "/", &path)) != RT_NULL && path != RT_NULL) + while ((file = strtok_r(RT_NULL, "/", &path)) != RT_NULL && path[0] != 0) { LOOKUP3args args; LOOKUP3res res;