fs/littlefs: Convert the lfs_file_size error code to POSIX's

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
This commit is contained in:
Xiang Xiao 2022-03-27 13:24:20 +08:00 committed by Xiang Xiao
parent 1146ff2f61
commit 37d7298f34

View File

@ -670,7 +670,7 @@ static int littlefs_fstat(FAR const struct file *filep, FAR struct stat *buf)
if (buf->st_size < 0)
{
return buf->st_size;
return littlefs_convert_result(buf->st_size);
}
buf->st_mode = S_IRWXO | S_IRWXG | S_IRWXU | S_IFREG;