mirror of
https://github.com/apache/nuttx.git
synced 2026-05-31 05:55:46 +08:00
fs/vfs: Fix after recent changes. write() was return negative values in errno. Noted by Jussi Kivilinna.
This commit is contained in:
+1
-1
@@ -246,7 +246,7 @@ ssize_t write(int fd, FAR const void *buf, size_t nbytes)
|
|||||||
ret = nx_write(fd, buf, nbytes);
|
ret = nx_write(fd, buf, nbytes);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
{
|
{
|
||||||
set_errno(ret);
|
set_errno(-ret);
|
||||||
ret = ERROR;
|
ret = ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user