[gnutls-devel] GnuTLS | Sockets: implement sendmsg()-like function on Win32 (!1377)
Read-only notification of GnuTLS library development activities
gnutls-devel at lists.gnutls.org
Mon Jan 25 15:15:09 CET 2021
Merge request https://gitlab.com/gnutls/gnutls/-/merge_requests/1377 was reviewed by Daiki Ueno
--
Daiki Ueno started a new discussion on lib/system/sockets.c: https://gitlab.com/gnutls/gnutls/-/merge_requests/1377#note_493250985
> + ++to_send_cnt) {
> + if (to_send_bytes + iovec[to_send_cnt].iov_len > SSIZE_MAX ||
> + iovec[to_send_cnt].iov_len > SSIZE_MAX) {
Aren't those two conditions around `||` redundant (i.e. given `to_send_bytes` is non-negative, the former condition is stricter than the latter)?
--
Daiki Ueno started a new discussion on lib/system/sockets.c: https://gitlab.com/gnutls/gnutls/-/merge_requests/1377#note_493250993
> + (space_left > ULONG_MAX ?
> + ULONG_MAX : space_left);
> + ovrflwn = true;
Can't it simply `break`?
--
Daiki Ueno started a new discussion on lib/system/sockets.c: https://gitlab.com/gnutls/gnutls/-/merge_requests/1377#note_493250999
> + bufs[to_send_cnt].len =
> + (unsigned long) iovec[to_send_cnt].iov_len;
> + to_send_bytes += iovec[to_send_cnt].iov_len;
I'm lost on this `to_send_bytes` tracking: do I understand correct that `WSASend` only accepts total bytes < `SSIZE_MAX`?
--
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/1377
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20210125/ff5fd705/attachment.html>
More information about the Gnutls-devel
mailing list