Update to tungstenite 0.15

pull/99/head
Sebastian Dröge 3 years ago committed by Sebastian Dröge
parent e1ef88d0e3
commit ee6c24d327
  1. 6
      Cargo.toml
  2. 3
      src/lib.rs

@ -21,8 +21,8 @@ gio-runtime = ["gio", "glib"]
async-tls = ["real-async-tls"] async-tls = ["real-async-tls"]
async-native-tls = ["async-std-runtime", "real-async-native-tls", "tungstenite/native-tls"] async-native-tls = ["async-std-runtime", "real-async-native-tls", "tungstenite/native-tls"]
tokio-native-tls = ["tokio-runtime", "real-tokio-native-tls", "real-native-tls", "tungstenite/native-tls"] tokio-native-tls = ["tokio-runtime", "real-tokio-native-tls", "real-native-tls", "tungstenite/native-tls"]
tokio-rustls-webpki-roots = ["tokio-runtime", "real-tokio-rustls", "webpki-roots", "tungstenite/rustls-tls"] tokio-rustls-webpki-roots = ["tokio-runtime", "real-tokio-rustls", "webpki-roots", "tungstenite/__rustls-tls"]
tokio-rustls-native-certs = ["tokio-runtime", "real-tokio-rustls", "rustls-native-certs", "tungstenite/rustls-tls"] tokio-rustls-native-certs = ["tokio-runtime", "real-tokio-rustls", "rustls-native-certs", "tungstenite/__rustls-tls"]
tokio-openssl = ["tokio-runtime", "real-tokio-openssl", "openssl"] tokio-openssl = ["tokio-runtime", "real-tokio-openssl", "openssl"]
verbose-logging = [] verbose-logging = []
@ -36,7 +36,7 @@ futures-io = { version = "0.3", default-features = false, features = ["std"] }
pin-project-lite = "0.2" pin-project-lite = "0.2"
[dependencies.tungstenite] [dependencies.tungstenite]
version = "0.14.0" version = "0.15.0"
default-features = false default-features = false
[dependencies.async-std] [dependencies.async-std]

@ -78,7 +78,6 @@ use tungstenite::{
HandshakeError, HandshakeError,
}, },
protocol::{Message, Role, WebSocket, WebSocketConfig}, protocol::{Message, Role, WebSocket, WebSocketConfig},
server,
}; };
#[cfg(feature = "async-std-runtime")] #[cfg(feature = "async-std-runtime")]
@ -195,7 +194,7 @@ where
C: Callback + Unpin, C: Callback + Unpin,
{ {
let f = handshake::server_handshake(stream, move |allow_std| { let f = handshake::server_handshake(stream, move |allow_std| {
server::accept_hdr_with_config(allow_std, callback, config) tungstenite::accept_hdr_with_config(allow_std, callback, config)
}); });
f.await.map_err(|e| match e { f.await.map_err(|e| match e {
HandshakeError::Failure(e) => e, HandshakeError::Failure(e) => e,

Loading…
Cancel
Save