Skip to content

Commit

Permalink
chore: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
lennartkloock committed Jan 26, 2024
1 parent 7d1a783 commit e77c8fb
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions video/ingest/src/ingest/connection.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,17 +99,17 @@ pub async fn handle<G: IngestGlobal, S: AsyncReadWrite>(global: Arc<G>, socket:
let fut = pin!(session.run());
let mut session = RtmpSession::new(fut, publish, data);

let Ok(Some(event)) = select! {
_ = global.ctx().done() => {
tracing::debug!("Global context closed, closing connection");
return;
},
d = session.publish() => d,
_ = tokio::time::sleep(Duration::from_secs(5)) => {
tracing::debug!("session timed out before publish request");
return;
},
} else {
let Ok(Some(event)) = select! (
_ = global.ctx().done() => {
tracing::debug!("Global context closed, closing connection");
return;
},
d = session.publish() => d,
_ = tokio::time::sleep(Duration::from_secs(5)) => {
tracing::debug!("session timed out before publish request");
return;
},
) else {
tracing::debug!("connection disconnected before publish");
return;
};
Expand Down

0 comments on commit e77c8fb

Please sign in to comment.