Skip to content

Commit

Permalink
store the sessions slab in a Rc<RefCell<>>
Browse files Browse the repository at this point in the history
then it can be shared with ProxyConfiguration implementors to simplify
further the API
  • Loading branch information
Geal authored and FlorentinDUBOIS committed Jul 13, 2022
1 parent 538741c commit e217e03
Show file tree
Hide file tree
Showing 5 changed files with 89 additions and 63 deletions.
2 changes: 1 addition & 1 deletion lib/src/http.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1700,7 +1700,7 @@ pub fn start(config: HttpListener, channel: ProxyChannel, max_buffers: usize, bu
event_loop,
channel,
ScmSocket::new(scm_server.into_raw_fd()),
sessions,
Rc::new(RefCell::new(sessions)),
pool,
backends,
Some(proxy),
Expand Down
2 changes: 1 addition & 1 deletion lib/src/https_openssl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2384,7 +2384,7 @@ pub fn start(config: HttpsListener, channel: ProxyChannel, max_buffers: usize, b
event_loop,
channel,
ScmSocket::new(scm_server.as_raw_fd()),
sessions,
Rc::new(RefCell::new(sessions)),
pool,
backends,
None,
Expand Down
2 changes: 1 addition & 1 deletion lib/src/https_rustls/configuration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -963,7 +963,7 @@ pub fn start(config: HttpsListener, channel: ProxyChannel, max_buffers: usize, b
event_loop,
channel,
ScmSocket::new(scm_server.as_raw_fd()),
sessions,
Rc::new(RefCell::new(sessions)),
pool,
backends,
None,
Expand Down

0 comments on commit e217e03

Please sign in to comment.