mirror of
https://codeberg.org/YGGverse/psocks.git
synced 2026-04-01 17:05:27 +00:00
implement current rules total snap
This commit is contained in:
parent
a77bc468b6
commit
b0475a3f24
5 changed files with 59 additions and 16 deletions
|
|
@ -2,7 +2,7 @@ mod snap;
|
|||
|
||||
use std::sync::atomic::{AtomicU64, Ordering};
|
||||
|
||||
pub use snap::Snap;
|
||||
pub use snap::{Rules, Snap};
|
||||
|
||||
#[derive(Default)]
|
||||
pub struct Total {
|
||||
|
|
@ -11,8 +11,9 @@ pub struct Total {
|
|||
}
|
||||
|
||||
impl Total {
|
||||
pub fn snap(&self, seconds_from_startup: u64) -> Snap {
|
||||
pub fn snap(&self, rules: Rules, seconds_from_startup: u64) -> Snap {
|
||||
Snap::shot(
|
||||
rules,
|
||||
self.request.load(Ordering::Relaxed),
|
||||
self.blocked.load(Ordering::Relaxed),
|
||||
seconds_from_startup,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue