INNER CODE UNIT · Rust
drop
xuzhougeng/wisp-science · crates/wisp-acp/src/lib.rs:462
fn drop(&mut self) {
if let Some(actor) = self.0.take() {
actor.abort();
}
}
}
/// Wait for a just-exited child's stderr reader to flush, returning as soon as
/// anything is captured. Bounded so a genuinely silent exit still returns.
async fn wait_for_stderr(stderr: &BoundedStderr) -> String {
// ponytail: 500ms ceiling (50×10ms). Only the fully-elapsed, no-stderr case
// waits the whole budget, and it's already an error path. Raise if a slower
// agent ever needs longer to flush.
for _ in 0..50 {
let snapshot = stderr.snapshot();
if !snapshot.is_empty() {
return snapshot;
}