In Linux 2.6.11 (and perhaps earlier), the sys_init_module system call takes 3 arguments. <br>
strace 4.5.11 expects the init_module system call to take 2 arguments.<br>
<br>
I've created a patch below to correct the problem. I assume that all the linux syscallent.h <br>
files will need to be modified, but I only modified the linux/syscallent.h file.<br>
<br>
Please let me know if you have any questions,<br>
<br>
James Lentini<br>
<a href="mailto:jlentini@gmail.google.com">jlentini@gmail.google.com</a><br>
<br>
--- strace-4.5.11/bjm.c~ 2004-09-03 23:39:20.000000000 -0400<br>
+++ strace-4.5.11/bjm.c 2005-05-09 21:48:41.801195000 -0400<br>
@@ -198,8 +198,9 @@<br>
struct tcb *tcp;<br>
{<br>
if (entering(tcp)) {<br>
- printpath(tcp, tcp->u_arg[0]);<br>
- tprintf(", %#lx", tcp->u_arg[1]);<br>
+ tprintf("%#lx, ", tcp->u_arg[0]);<br>
+ tprintf("%lu, ", tcp->u_arg[1]);<br>
+ printstr(tcp, tcp->u_arg[2], -1);<br>
}<br>
return 0;<br>
}<br>
<br>
--- strace-4.5.11/linux/syscallent.h~ 2005-02-01 23:17:00.000000000 -0500<br>
+++ strace-4.5.11/linux/syscallent.h 2005-05-09 20:58:26.993838000 -0400<br>
@@ -164,7 +164,7 @@<br>
{ 3,
0,
sys_mprotect,
"mprotect" }, /* 125 */<br>
{ 3,
TS,
sys_sigprocmask,
"sigprocmask" }, /* 126 */<br>
{ 2,
0,
sys_create_module, "create_module" }, /*
127 */<br>
- { 2,
0,
sys_init_module,
"init_module" }, /* 128 */<br>
+ { 3,
0,
sys_init_module,
"init_module" }, /* 128 */<br>
{ 1,
0,
sys_delete_module, "delete_module" }, /*
129 */<br>
{ 1,
0, sys_get_kernel_syms,
"get_kernel_syms"}, /* 130 */<br>
{ 4,
0,
sys_quotactl,
"quotactl" }, /* 131 */<br>
<br>