// boundary, start, &comp.name, &client.ic);
let (reply_to, reply_recv) = tokio::sync::oneshot::channel();
+ trace!("{} request xxx={}", &client.ic, initial.len());
let wreq = WebRequest {
initial,
initial_remaining,
warnings: mem::take(&mut warnings),
reply_to
};
- trace!("{} request", &client.ic);
client.web.try_send(wreq)
.map_err(|_| anyhow!("client task shut down!"))?;
let WebRequest {
initial, initial_remaining, length_hint, mut body,
boundary_finder,
- reply_to, warnings,
+ reply_to, mut warnings,
} = req.ok_or_else(|| anyhow!("webservers all shut down!"))?;
match async {
&mut body
).await.context("read request body")?;
- let (meta, comps) =
+ let (meta, mut comps) =
multipart::ComponentIterator::resume_mid_component(
&whole_request[initial_used..],
boundary_finder
let server, client = meta.parse()?.unwrap_or(server);
}
+ while let Some(comp) = comps.next(&mut warnings, PartName::d)? {
+ if comp.name != PartName::d {
+ warnings.add(&format_args!("unexpected part {:?}", comp.name))?;
+ }
+ dbg!(comp.name, DumpHex(comp.payload));
+ }
+
Ok::<_,AE>(())
}.await {
Ok(()) => outstanding.push_back(Outstanding {