diff options
author | Baitinq <manuelpalenzuelamerino@gmail.com> | 2024-01-17 00:33:15 +0100 |
---|---|---|
committer | Baitinq <manuelpalenzuelamerino@gmail.com> | 2024-01-17 00:33:15 +0100 |
commit | d650d42dac5a9280747ac6741b770f7f3c5b9a50 (patch) | |
tree | 990dfbf80b856cf869f931d9333991a5847a8fa9 /fs-tracer-common | |
parent | Add comments (diff) | |
download | fs-tracer-d650d42dac5a9280747ac6741b770f7f3c5b9a50.tar.gz fs-tracer-d650d42dac5a9280747ac6741b770f7f3c5b9a50.tar.bz2 fs-tracer-d650d42dac5a9280747ac6741b770f7f3c5b9a50.zip |
Match syscall_enter and syscall_exits to get return value
Diffstat (limited to 'fs-tracer-common')
-rw-r--r-- | fs-tracer-common/src/lib.rs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/fs-tracer-common/src/lib.rs b/fs-tracer-common/src/lib.rs index 77ee0e5..9be9774 100644 --- a/fs-tracer-common/src/lib.rs +++ b/fs-tracer-common/src/lib.rs @@ -8,19 +8,22 @@ use core::str; pub struct WriteSyscallBPF { pub pid: u32, pub fd: u64, - pub buf: [u8; 128], + pub buf: [u8; 96], pub count: u64, + + pub ret: i64, } unsafe impl Sync for WriteSyscallBPF {} impl fmt::Debug for WriteSyscallBPF { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { - f.debug_struct("WriteSyscallArgs") + f.debug_struct("WriteSyscallBPF") .field("pid", &self.pid) .field("fd", &self.fd) .field("buf", &str::from_utf8(&self.buf).unwrap_or("") ) .field("count", &self.count) + .field("ret", &self.ret) .finish() } } \ No newline at end of file |