mirror of
https://github.com/librespot-org/librespot.git
synced 2024-12-18 17:11:53 +00:00
Fix tokio depreciation warnings
This commit is contained in:
parent
c22a6d1fa0
commit
fe4b71d76c
5 changed files with 6 additions and 3 deletions
1
Cargo.lock
generated
1
Cargo.lock
generated
|
@ -541,6 +541,7 @@ dependencies = [
|
||||||
"serde_derive 0.9.15 (registry+https://github.com/rust-lang/crates.io-index)",
|
"serde_derive 0.9.15 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"serde_json 0.9.10 (registry+https://github.com/rust-lang/crates.io-index)",
|
"serde_json 0.9.10 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"shannon 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"shannon 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
"tokio-codec 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"tokio-core 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
"tokio-core 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"tokio-io 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
|
"tokio-io 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
|
|
@ -30,6 +30,7 @@ serde = "0.9.6"
|
||||||
serde_derive = "0.9.6"
|
serde_derive = "0.9.6"
|
||||||
serde_json = "0.9.5"
|
serde_json = "0.9.5"
|
||||||
shannon = "0.2.0"
|
shannon = "0.2.0"
|
||||||
|
tokio-codec = "0.1.1"
|
||||||
tokio-core = "0.1.2"
|
tokio-core = "0.1.2"
|
||||||
tokio-io = "0.1"
|
tokio-io = "0.1"
|
||||||
url = "1.7.0"
|
url = "1.7.0"
|
||||||
|
|
|
@ -7,7 +7,7 @@ use protobuf::{self, Message};
|
||||||
use rand::thread_rng;
|
use rand::thread_rng;
|
||||||
use std::io::{self, Read};
|
use std::io::{self, Read};
|
||||||
use std::marker::PhantomData;
|
use std::marker::PhantomData;
|
||||||
use tokio_io::codec::Framed;
|
use tokio_codec::{Decoder, Framed};
|
||||||
use tokio_io::io::{read_exact, write_all, ReadExact, Window, WriteAll};
|
use tokio_io::io::{read_exact, write_all, ReadExact, Window, WriteAll};
|
||||||
use tokio_io::{AsyncRead, AsyncWrite};
|
use tokio_io::{AsyncRead, AsyncWrite};
|
||||||
|
|
||||||
|
@ -73,7 +73,7 @@ impl<T: AsyncRead + AsyncWrite> Future for Handshake<T> {
|
||||||
ClientResponse(ref mut codec, ref mut write) => {
|
ClientResponse(ref mut codec, ref mut write) => {
|
||||||
let (connection, _) = try_ready!(write.poll());
|
let (connection, _) = try_ready!(write.poll());
|
||||||
let codec = codec.take().unwrap();
|
let codec = codec.take().unwrap();
|
||||||
let framed = connection.framed(codec);
|
let framed = codec.framed(connection);
|
||||||
return Ok(Async::Ready(framed));
|
return Ok(Async::Ready(framed));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,7 +10,7 @@ use std::io;
|
||||||
use std::net::ToSocketAddrs;
|
use std::net::ToSocketAddrs;
|
||||||
use tokio_core::net::TcpStream;
|
use tokio_core::net::TcpStream;
|
||||||
use tokio_core::reactor::Handle;
|
use tokio_core::reactor::Handle;
|
||||||
use tokio_io::codec::Framed;
|
use tokio_codec::Framed;
|
||||||
use url::Url;
|
use url::Url;
|
||||||
|
|
||||||
use authentication::Credentials;
|
use authentication::Credentials;
|
||||||
|
|
|
@ -28,6 +28,7 @@ extern crate rpassword;
|
||||||
extern crate serde;
|
extern crate serde;
|
||||||
extern crate serde_json;
|
extern crate serde_json;
|
||||||
extern crate shannon;
|
extern crate shannon;
|
||||||
|
extern crate tokio_codec;
|
||||||
extern crate tokio_core;
|
extern crate tokio_core;
|
||||||
extern crate tokio_io;
|
extern crate tokio_io;
|
||||||
extern crate url;
|
extern crate url;
|
||||||
|
|
Loading…
Reference in a new issue