acassis commented on code in PR #9576:
URL: https://github.com/apache/nuttx/pull/9576#discussion_r1236026431
##########
fs/vfs/fs_sendfile.c:
##########
@@ -244,6 +244,11 @@ static ssize_t copyfile(FAR struct file *outfile, FAR
struct file *infile,
ssize_t file_sendfile(FAR struct file *outfile, FAR struct file *infile,
off_t *offset, size_t count)
{
+ if (count == 0)
+ {
+ return 0;
Review Comment:
please add a nwarn() to let the user know that is tried to send a packet
with 0 bytes. I think that kind message could have helped you with your
application! ;-)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]