mirror of
https://github.com/Noratrieb/haesli.git
synced 2026-01-16 20:55:03 +01:00
sending frames works
This commit is contained in:
parent
fcf531df43
commit
217a419ef1
4 changed files with 296 additions and 299 deletions
|
|
@ -51,11 +51,17 @@ impl Connection {
|
|||
locales: vec![],
|
||||
});
|
||||
|
||||
let fut = classes::write::write_method(start_method, &mut self.stream);
|
||||
warn!(size = %std::mem::size_of_val(&fut), "that future is big");
|
||||
// todo fix out_buffer buffer things :spiral_eyes:
|
||||
// maybe have a `size` method on `Class` and use `AsyncWrite`? oh god no that's horrible
|
||||
// frame::write_frame(&mut self.stream, Frame {})?;
|
||||
let mut payload = Vec::with_capacity(64);
|
||||
classes::write::write_method(start_method, &mut payload)?;
|
||||
frame::write_frame(
|
||||
&mut self.stream,
|
||||
&Frame {
|
||||
kind: FrameType::Method,
|
||||
channel: 0,
|
||||
payload,
|
||||
},
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue