mirror of
https://github.com/apache/nuttx.git
synced 2026-05-16 13:56:00 +08:00
880d78f903
If sendfile() is called with a zero count, it will nevertheless try to send the data. This is mostly meaningless, it causes waste of resources, and in some cases delays. This commit adds special handling for this case, allowing sendfile to return immediately zero. The new behavior is in line with the Linux variant of sendfile.