Remove pin<box further

This commit is contained in:
Igor Katson 2024-02-27 08:17:15 +00:00
parent a001bb8c97
commit 3cecb1a4c3
No known key found for this signature in database
GPG key ID: B4EC22B66D61A3F5
2 changed files with 5 additions and 5 deletions

View file

@ -1,14 +1,13 @@
use std::net::SocketAddr;
use std::pin::Pin;
use std::sync::Arc;
use std::time::Duration;
use anyhow::bail;
use anyhow::Context;
use futures::future::Either;
use futures::stream::BoxStream;
use futures::stream::FuturesUnordered;
use futures::FutureExt;
use futures::Stream;
use futures::StreamExt;
use tracing::debug;
use tracing::error_span;
@ -67,7 +66,7 @@ impl TrackerComms {
stats: Box<dyn TorrentStatsProvider>,
force_interval: Option<Duration>,
tcp_listen_port: Option<u16>,
) -> Option<Pin<Box<dyn Stream<Item = SocketAddr> + Send + 'static>>> {
) -> Option<BoxStream<'static, SocketAddr>> {
let trackers = trackers
.into_iter()
.filter_map(|t| match Url::parse(&t) {