Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/dialog/dialog.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ use crate::{
transport::SipAddr,
Result,
};
use futures::FutureExt;
use rsip::{
headers::Route,
message::HasHeaders,
Expand Down Expand Up @@ -792,7 +793,7 @@ impl DialogInner {
}

pub(super) async fn do_request(&self, request: Request) -> Result<Option<Response>> {
self.send_dialog_request(request).await
self.send_dialog_request(request).boxed().await
}

pub(super) fn transition(&self, state: DialogState) -> Result<()> {
Expand Down
3 changes: 2 additions & 1 deletion src/dialog/invitation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ use crate::{
transport::SipAddr,
Result,
};
use futures::FutureExt;
use rsip::{
prelude::{HeadersExt, ToTypedHeader},
Request, Response,
Expand Down Expand Up @@ -430,7 +431,7 @@ impl DialogLayer {
id: &id,
};

let r = dialog.process_invite(tx).await;
let r = dialog.process_invite(tx).boxed().await;
self.inner
.dialogs
.write()
Expand Down
3 changes: 1 addition & 2 deletions src/dialog/tests/test_client_dialog.rs
Original file line number Diff line number Diff line change
Expand Up @@ -362,8 +362,7 @@ async fn test_make_request_preserves_remote_target_and_route_order() -> crate::R
.expect("route-enabled request should resolve to a destination");
let expected_destination = Uri::try_from("sip:proxy2.example.com:5070;transport=tcp;lr")?;
assert_eq!(
&*destination,
&expected_destination,
&*destination, &expected_destination,
"First Route entry must determine the transport destination"
);

Expand Down
3 changes: 1 addition & 2 deletions src/transport/stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ where

let mut codec = SipCodec::new();
let mut buffer = BytesMut::with_capacity(MAX_SIP_MESSAGE_SIZE);
let mut read_buf = [0u8; MAX_SIP_MESSAGE_SIZE];

let mut read_buf = vec![0u8; MAX_SIP_MESSAGE_SIZE];
loop {
use tokio::io::AsyncReadExt;
match read_half.read(&mut read_buf).await {
Expand Down