mirror of
https://github.com/actix/actix-web.git
synced 2024-11-26 19:41:12 +00:00
Fix segfault in ServerSettings::get_response_builder()
This commit is contained in:
parent
487a713ca0
commit
9306631d6e
3 changed files with 18 additions and 2 deletions
|
@ -1,5 +1,10 @@
|
||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
|
## 0.6.4 (2018-05-11)
|
||||||
|
|
||||||
|
* Fix segfault in ServerSettings::get_response_builder()
|
||||||
|
|
||||||
|
|
||||||
## 0.6.3 (2018-05-10)
|
## 0.6.3 (2018-05-10)
|
||||||
|
|
||||||
* Add `Router::with_async()` method for async handler registration.
|
* Add `Router::with_async()` method for async handler registration.
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "actix-web"
|
name = "actix-web"
|
||||||
version = "0.6.3"
|
version = "0.6.4"
|
||||||
authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
|
authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
|
||||||
description = "Actix web is a simple, pragmatic and extremely fast web framework for Rust."
|
description = "Actix web is a simple, pragmatic and extremely fast web framework for Rust."
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
|
|
|
@ -16,7 +16,6 @@ use body::Body;
|
||||||
use httpresponse::{HttpResponse, HttpResponseBuilder, HttpResponsePool};
|
use httpresponse::{HttpResponse, HttpResponseBuilder, HttpResponsePool};
|
||||||
|
|
||||||
/// Various server settings
|
/// Various server settings
|
||||||
#[derive(Clone)]
|
|
||||||
pub struct ServerSettings {
|
pub struct ServerSettings {
|
||||||
addr: Option<net::SocketAddr>,
|
addr: Option<net::SocketAddr>,
|
||||||
secure: bool,
|
secure: bool,
|
||||||
|
@ -28,6 +27,18 @@ pub struct ServerSettings {
|
||||||
unsafe impl Sync for ServerSettings {}
|
unsafe impl Sync for ServerSettings {}
|
||||||
unsafe impl Send for ServerSettings {}
|
unsafe impl Send for ServerSettings {}
|
||||||
|
|
||||||
|
impl Clone for ServerSettings {
|
||||||
|
fn clone(&self) -> Self {
|
||||||
|
ServerSettings {
|
||||||
|
addr: self.addr,
|
||||||
|
secure: self.secure,
|
||||||
|
host: self.host.clone(),
|
||||||
|
cpu_pool: self.cpu_pool.clone(),
|
||||||
|
responses: HttpResponsePool::pool(),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
struct InnerCpuPool {
|
struct InnerCpuPool {
|
||||||
cpu_pool: UnsafeCell<Option<CpuPool>>,
|
cpu_pool: UnsafeCell<Option<CpuPool>>,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue