rpmsgfs: fix nx_style

Signed-off-by: ligd <liguiding1@xiaomi.com>
This commit is contained in:
ligd 2022-07-22 12:38:27 +08:00 committed by Petro Karashchenko
parent 572d865034
commit 1e5568b030
2 changed files with 2 additions and 2 deletions

View File

@ -484,7 +484,7 @@ ssize_t rpmsgfs_client_read(FAR void *handle, int fd,
out:
nxsem_destroy(&cookie.sem);
return read.iov_len ? read.iov_len : ret;
return read.iov_len > 0 ? read.iov_len : ret;
}
ssize_t rpmsgfs_client_write(FAR void *handle, int fd,

View File

@ -378,7 +378,7 @@ static int rpmsgfs_read_handler(FAR struct rpmsg_endpoint *ept,
while (read < msg->count)
{
rsp = rpmsg_get_tx_payload_buffer(ept, &space, true);
if (!rsp)
if (rsp == NULL)
{
return -ENOMEM;
}