MCPcopy Create free account
hub / github.com/CodSpeedHQ/codspeed / drop

Method drop

src/executor/helpers/linux_sysctl.rs:27–35  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

25
26impl Drop for LinuxSysctl {
27 fn drop(&mut self) {
28 let Some(value) = self.previous else {
29 return;
30 };
31
32 if let Err(error) = ensure_sysctl(self.name, value) {
33 warn!("Failed to restore {}={value}: {error}", self.name);
34 }
35 }
36}
37
38pub fn ensure_linux_profiling_sysctls() -> Result<Vec<LinuxSysctl>> {

Callers

nothing calls this directly

Calls 1

ensure_sysctlFunction · 0.85

Tested by

no test coverage detected