mirror of
https://github.com/google/sandboxed-api.git
synced 2024-03-22 13:11:30 +08:00
Add explicit casts to avoid build failures
PiperOrigin-RevId: 514698583 Change-Id: I0ebf2c14a74330ead3a362a48d1776060ea70fbe
This commit is contained in:
parent
a8db8bfcf7
commit
e46a526865
|
@ -95,10 +95,13 @@ void SyscallTrap::SignalHandlerImpl(int nr, siginfo_t* info, void* context) {
|
||||||
#elif defined(SAPI_ARM)
|
#elif defined(SAPI_ARM)
|
||||||
auto* registers = &uctx->uc_mcontext.arm_r0;
|
auto* registers = &uctx->uc_mcontext.arm_r0;
|
||||||
#endif
|
#endif
|
||||||
int syscall_nr = registers[kRegSyscall];
|
int syscall_nr = static_cast<int>(registers[kRegSyscall]);
|
||||||
Args args = {registers[kRegArgs[0]], registers[kRegArgs[1]],
|
Args args = {static_cast<uintptr_t>(registers[kRegArgs[0]]),
|
||||||
registers[kRegArgs[2]], registers[kRegArgs[3]],
|
static_cast<uintptr_t>(registers[kRegArgs[1]]),
|
||||||
registers[kRegArgs[4]], registers[kRegArgs[5]]};
|
static_cast<uintptr_t>(registers[kRegArgs[2]]),
|
||||||
|
static_cast<uintptr_t>(registers[kRegArgs[3]]),
|
||||||
|
static_cast<uintptr_t>(registers[kRegArgs[4]]),
|
||||||
|
static_cast<uintptr_t>(registers[kRegArgs[5]])};
|
||||||
uintptr_t rv;
|
uintptr_t rv;
|
||||||
if (!handler_(syscall_nr, args, &rv)) {
|
if (!handler_(syscall_nr, args, &rv)) {
|
||||||
InvokeOldAct(nr, info, context);
|
InvokeOldAct(nr, info, context);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user