build(deps): bump isahc from 0.9.14 to 1.0.2
Bumps [isahc](https://github.com/sagebind/isahc) from 0.9.14 to 1.0.2. - [Release notes](https://github.com/sagebind/isahc/releases) - [Commits](https://github.com/sagebind/isahc/compare/0.9.14...1.0.2) Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
This commit is contained in:
parent
49a69c8109
commit
54367aafa0
|
@ -1227,12 +1227,13 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "flume"
|
name = "flume"
|
||||||
version = "0.9.2"
|
version = "0.10.1"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "1bebadab126f8120d410b677ed95eee4ba6eb7c6dd8e34a5ec88a08050e26132"
|
checksum = "0362ef9c4c1fa854ff95b4cb78045a86e810d804dc04937961988b45427104a9"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"futures-core",
|
"futures-core",
|
||||||
"futures-sink",
|
"futures-sink",
|
||||||
|
"pin-project 1.0.2",
|
||||||
"spinning_top",
|
"spinning_top",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
@ -1808,11 +1809,10 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "isahc"
|
name = "isahc"
|
||||||
version = "0.9.14"
|
version = "1.0.2"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "e2948a0ce43e2c2ef11d7edf6816508998d99e13badd1150be0914205df9388a"
|
checksum = "990caf8da378f0127ade48d4db60ed19f9e7dd3094a4278ef51cf3d56982e28b"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bytes",
|
|
||||||
"crossbeam-utils",
|
"crossbeam-utils",
|
||||||
"curl",
|
"curl",
|
||||||
"curl-sys",
|
"curl-sys",
|
||||||
|
|
|
@ -23,7 +23,7 @@ webbrowser = "0.5.5"
|
||||||
url = "2.2.0"
|
url = "2.2.0"
|
||||||
clipboard = "0.5.0"
|
clipboard = "0.5.0"
|
||||||
dirs = "3.0"
|
dirs = "3.0"
|
||||||
isahc = "0.9.14"
|
isahc = "1.0.2"
|
||||||
tinyfiledialogs = {git ="https://github.com/jdm/tinyfiledialogs-rs", rev="1a235d1"}
|
tinyfiledialogs = {git ="https://github.com/jdm/tinyfiledialogs-rs", rev="1a235d1"}
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies]
|
[target.'cfg(windows)'.dependencies]
|
||||||
|
|
|
@ -13,8 +13,7 @@ mod ui;
|
||||||
use crate::custom_event::RuffleEvent;
|
use crate::custom_event::RuffleEvent;
|
||||||
use crate::executor::GlutinAsyncExecutor;
|
use crate::executor::GlutinAsyncExecutor;
|
||||||
use clap::Clap;
|
use clap::Clap;
|
||||||
use isahc::config::RedirectPolicy;
|
use isahc::{config::RedirectPolicy, prelude::*, HttpClient};
|
||||||
use isahc::prelude::*;
|
|
||||||
use ruffle_core::{
|
use ruffle_core::{
|
||||||
backend::audio::{AudioBackend, NullAudioBackend},
|
backend::audio::{AudioBackend, NullAudioBackend},
|
||||||
Player,
|
Player,
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
//! Navigator backend for web
|
//! Navigator backend for web
|
||||||
|
|
||||||
use crate::custom_event::RuffleEvent;
|
use crate::custom_event::RuffleEvent;
|
||||||
use isahc::config::RedirectPolicy;
|
use isahc::{config::RedirectPolicy, prelude::*, AsyncReadResponseExt, HttpClient, Request};
|
||||||
use isahc::prelude::*;
|
|
||||||
use ruffle_core::backend::navigator::{
|
use ruffle_core::backend::navigator::{
|
||||||
NavigationMethod, NavigatorBackend, OwnedFuture, RequestOptions,
|
NavigationMethod, NavigatorBackend, OwnedFuture, RequestOptions,
|
||||||
};
|
};
|
||||||
|
@ -10,7 +9,6 @@ use ruffle_core::indexmap::IndexMap;
|
||||||
use ruffle_core::loader::Error;
|
use ruffle_core::loader::Error;
|
||||||
use std::borrow::Cow;
|
use std::borrow::Cow;
|
||||||
use std::fs;
|
use std::fs;
|
||||||
use std::io::Read;
|
|
||||||
use std::rc::Rc;
|
use std::rc::Rc;
|
||||||
use std::sync::mpsc::Sender;
|
use std::sync::mpsc::Sender;
|
||||||
use std::time::{Duration, Instant};
|
use std::time::{Duration, Instant};
|
||||||
|
@ -144,12 +142,17 @@ impl NavigatorBackend for ExternalNavigatorBackend {
|
||||||
.body(body_data)
|
.body(body_data)
|
||||||
.map_err(|e| Error::FetchError(e.to_string()))?;
|
.map_err(|e| Error::FetchError(e.to_string()))?;
|
||||||
|
|
||||||
let response = client
|
let mut response = client
|
||||||
.send_async(body)
|
.send_async(body)
|
||||||
.await
|
.await
|
||||||
.map_err(|e| Error::FetchError(e.to_string()))?;
|
.map_err(|e| Error::FetchError(e.to_string()))?;
|
||||||
|
|
||||||
response_to_bytes(response).map_err(|e| Error::FetchError(e.to_string()))
|
let mut buffer = vec![];
|
||||||
|
response
|
||||||
|
.copy_to(&mut buffer)
|
||||||
|
.await
|
||||||
|
.map_err(|e| Error::FetchError(e.to_string()))?;
|
||||||
|
Ok(buffer)
|
||||||
}),
|
}),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -184,9 +187,3 @@ impl NavigatorBackend for ExternalNavigatorBackend {
|
||||||
url
|
url
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fn response_to_bytes(res: Response<Body>) -> Result<Vec<u8>, std::io::Error> {
|
|
||||||
let mut buffer: Vec<u8> = Vec::new();
|
|
||||||
res.into_body().read_to_end(&mut buffer)?;
|
|
||||||
Ok(buffer)
|
|
||||||
}
|
|
||||||
|
|
Loading…
Reference in New Issue