llvm-project
57b09398 - [libc] Fix alarm layout mismatch on 32-bit time64 (#201276)

Commit
6 days ago
[libc] Fix alarm layout mismatch on 32-bit time64 (#201276) Fixed alarm implementation on 32-bit architectures with 64-bit time_t (like RISC-V 32-bit). The SYS_setitimer syscall on these platforms expects the legacy 32-bit struct itimerval (with 32-bit tv_sec and tv_usec). Convert the arguments to this layout before invoking the syscall to avoid the kernel misinterpreting the timeout. Assisted-by: Automated tooling, human reviewed.
Author
Parents
Loading