mirror of
https://github.com/actix/actix-extras.git
synced 2025-03-15 18:03:06 +01:00
Add step to release memory
This commit is contained in:
parent
ca67ea4faa
commit
b3c5934b00
@ -140,6 +140,10 @@ impl Stream for StreamingBody {
|
||||
return Poll::Ready(None);
|
||||
}
|
||||
|
||||
// When we have a moment (pending) allow the BigBytes to release memory
|
||||
// arbitrary 8KB (page size)
|
||||
this.buf.clear(1024 * 8);
|
||||
|
||||
Poll::Pending
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user