Skip to content

Commit 2fc0a66

Browse files
dianpopadpopa
authored and
dpopa
committed
sys_util: completely remove syslog functionality...
...and all related stuff Signed-off-by: Diana Popa <[email protected]>
1 parent 7056894 commit 2fc0a66

File tree

2 files changed

+0
-624
lines changed

2 files changed

+0
-624
lines changed

sys_util/src/lib.rs

-13
Original file line numberDiff line numberDiff line change
@@ -36,16 +36,3 @@ pub use libc_ioctl::*;
3636

3737
pub use mmap::Error as MmapError;
3838
pub use guest_memory::Error as GuestMemoryError;
39-
40-
use libc::{c_long, pid_t, syscall};
41-
42-
use syscall_defines::linux::LinuxSyscall::SYS_getpid;
43-
44-
/// This bypasses `libc`'s caching `getpid(2)` wrapper which can be invalid if a raw clone was used
45-
/// elsewhere.
46-
/// TODO(dpopa@): get rid of this when syslog is gone too
47-
#[inline(always)]
48-
pub fn getpid() -> pid_t {
49-
// Safe because this syscall can never fail and we give it a valid syscall number.
50-
unsafe { syscall(SYS_getpid as c_long) as pid_t }
51-
}

0 commit comments

Comments
 (0)