Skip to content

Commit

Permalink
fix(modern_bpf): fix wrong sign when getting quotactl cmd arg
Browse files Browse the repository at this point in the history
Signed-off-by: Roberto Scolaro <[email protected]>
  • Loading branch information
therealbobo authored and poiana committed Jan 29, 2024
1 parent eb09ef2 commit ceda218
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ int BPF_PROG(quotactl_x,
unsigned long special_pointer = extract__syscall_argument(regs, 1);
auxmap__store_charbuf_param(auxmap, special_pointer, MAX_PATH, USER);

int32_t cmd = (int32_t)extract__syscall_argument(regs, 0);
uint32_t cmd = (uint32_t)extract__syscall_argument(regs, 0);
uint16_t scap_cmd = quotactl_cmd_to_scap(cmd);

/* The `addr` argument is the address of an optional, command-
Expand Down

0 comments on commit ceda218

Please sign in to comment.