This makes interface a bit irregular otherwise.
* defs.h (syscall_name): Clarify description.
* syscall.c (syscall_name): Do not call shuffle_scno.
* printsiginfo.c (print_si_info) <case SIGSYS>: Use shuffle_scno.
extern kernel_ulong_t get_rt_sigframe_addr(struct tcb *);
/**
- * Convert syscall number to syscall name.
+ * Convert a (shuffled) syscall number to the corresponding syscall name.
*
* @param scno Syscall number.
* @return String literal corresponding to the syscall number in case latter
* - Looks like there are no other cases where SIGSYS
* is delivered from the kernel so far.
*/
- const char *scname =
- syscall_name((unsigned) sip->si_syscall);
+ const char *scname = syscall_name(shuffle_scno(
+ (unsigned) sip->si_syscall));
tprints(", si_call_addr=");
printaddr(ptr_to_kulong(sip->si_call_addr));
const char *
syscall_name(kernel_ulong_t scno)
{
- scno = shuffle_scno(scno);
-
return scno_is_valid(scno) ? sysent[scno].sys_name : NULL;
}