Implement process_vm_writev decoder

* process.c (sys_process_vm_writev): New function.
* linux/syscall.h (sys_process_vm_writev): New prototype.
This commit is contained in:
Дмитрий Левин 2012-03-10 14:14:49 +00:00
parent 0bfd74436d
commit 039521051e
2 changed files with 26 additions and 0 deletions

View File

@ -175,6 +175,7 @@ int sys_preadv();
int sys_pselect6();
int sys_ptrace();
int sys_process_vm_readv();
int sys_process_vm_writev();
int sys_putpmsg();
int sys_pwrite();
int sys_pwritev();

View File

@ -2774,3 +2774,28 @@ sys_process_vm_readv(struct tcb *tcp)
}
return 0;
}
int
sys_process_vm_writev(struct tcb *tcp)
{
if (entering(tcp)) {
/* arg 1: pid */
tprintf("%ld, ", tcp->u_arg[0]);
/* arg 2: local iov */
if (syserror(tcp))
tprintf("%#lx", tcp->u_arg[1]);
else
tprint_iov(tcp, tcp->u_arg[2], tcp->u_arg[1], 1);
/* arg 3: local iovcnt */
tprintf(", %lu, ", tcp->u_arg[2]);
/* arg 4: remote iov */
if (syserror(tcp))
tprintf("%#lx", tcp->u_arg[3]);
else
tprint_iov(tcp, tcp->u_arg[4], tcp->u_arg[3], 0);
/* arg 5: remote iovcnt */
/* arg 6: flags */
tprintf(", %lu, %lu", tcp->u_arg[4], tcp->u_arg[5]);
}
return 0;
}