Changes
Started by upstream project gerrit-libosmocore #2370
Started 3 hr 20 min ago
Queued 7.3 sec
Took 3 min 3 sec
on built-in
osmo_io: Rewrite iofd_handle_send_completion() to fix multiple issues
Previous implementation had multiple issues, which this patch addresses:
* Didn't call user cb updating completed bytes for a given msg which had
a partial write.
* rc checks against "Incomplete write" were wrong, because rc was not
being decremented with previous msgs idxs being processed.
* Didn't take into account the write(0, fd, buf) = 0 valid user case for
regular files.
The rewrite also simplifies the logic by splitting the "rc < 0" (error) paths
from the "rc >= 0" (successful) paths.
Related: SYS#7842
Change-Id: Ia016e4df7be5e534a8212f7271caff9779e08eb1
Previous implementation had multiple issues, which this patch addresses:
* Didn't call user cb updating completed bytes for a given msg which had
a partial write.
* rc checks against "Incomplete write" were wrong, because rc was not
being decremented with previous msgs idxs being processed.
* Didn't take into account the write(0, fd, buf) = 0 valid user case for
regular files.
The rewrite also simplifies the logic by splitting the "rc < 0" (error) paths
from the "rc >= 0" (successful) paths.
Related: SYS#7842
Change-Id: Ia016e4df7be5e534a8212f7271caff9779e08eb1