0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-18 07:50:57 +01:00

ircd: Assurances the full-transfer socket methods do just that.

This commit is contained in:
Jason Volk 2017-04-06 17:46:26 -07:00
parent 8955328479
commit 5b40a9ad91

View file

@ -206,7 +206,9 @@ size_t
write(socket &socket,
const iov &bufs)
{
return socket.write(bufs);
const auto wrote(socket.write(bufs));
assert(wrote == size(bufs));
return wrote;
}
inline
@ -234,7 +236,7 @@ socket::write(const iov &bufs)
{
return io(*this, out, [&]
{
return async_write(ssl, bufs, yield(continuation()));
return async_write(ssl, bufs, asio::transfer_all(), yield(continuation()));
});
}
@ -245,7 +247,7 @@ socket::write(const iov &bufs,
{
return io(*this, out, [&]
{
return async_write(ssl, bufs, yield(continuation())[ec]);
return async_write(ssl, bufs, asio::transfer_all(), yield(continuation())[ec]);
});
}