0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2025-01-14 00:34:18 +01:00

ircd::buffer: window_buffer closure returns completed().

This commit is contained in:
Jason Volk 2018-03-17 11:39:33 -07:00
parent 30eb9178bd
commit 96818c9a46

View file

@ -35,7 +35,7 @@ struct ircd::buffer::window_buffer
explicit operator const_buffer() const; explicit operator const_buffer() const;
mutable_buffer completed(); mutable_buffer completed();
void operator()(const closure &closure); const_buffer operator()(const closure &closure);
window_buffer(const mutable_buffer &base); window_buffer(const mutable_buffer &base);
}; };
@ -46,10 +46,11 @@ ircd::buffer::window_buffer::window_buffer(const mutable_buffer &base)
,base{base} ,base{base}
{} {}
inline void inline ircd::buffer::const_buffer
ircd::buffer::window_buffer::operator()(const closure &closure) ircd::buffer::window_buffer::operator()(const closure &closure)
{ {
consume(*this, closure(*this)); consume(*this, closure(*this));
return completed();
} }
/// View the completed portion of the stream /// View the completed portion of the stream