FUCK THIS BULLSHIT. I LITERALLY JUST WANT A BUFFERED STREAM. WHY IS THERE NO LIBRARY FOR THIS, WHY IS THIS NOT THERE BY DEFAULT. FUCK EVERYTHING. I HATE THIS STUPID BOILERPLATE

Fortune for rsh's current commit: Small blessing − 小吉
sock-buffering
Avril 3 years ago
parent 56306fae83
commit 7cad244c16
Signed by: flanchan
GPG Key ID: 284488987C31F630

@ -161,7 +161,8 @@ impl<T: AsyncRead + Unpin + ?Sized, const SIZE: usize> Buffered<T, SIZE>
let sz = self.buffer.len();
Ok(if sz != SIZE { // < SIZE
use tokio::prelude::*;
// XXXX::: I think the issue is, this function comes before the await point, meaning it is ran twice after the first poll? I have no fucking idea. I hate this... I just want a god damn buffered stream. WHY IS THIS SO CANCEROUS.
self.buffer.resize(SIZE, 0);
let done = {

Loading…
Cancel
Save