Remove redundant parsers
* desc.c (sys_dup): Remove.
* file.c (sys_pivotroot, sys_rmdir, sys_fchdir, sys_chroot, sys_fchroot,
sys_unlink, sys_symlink, sys_rename): Remove.
* linux/syscall.h (sys_chroot, sys_dup, sys_fchdir, sys_pivotroot,
sys_rename, sys_rmdir, sys_symlink, sys_unlink): Remove.
* linux/dummy.h: Add aliases for sys_chroot, sys_dup, sys_pivotroot,
sys_rename, sys_rmdir, sys_symlink, sys_unlink.
* pathtrace.c (pathtrace_match): Update.
* sunos4/dummy.h: Add aliases for sys_chroot, sys_dup, sys_fchdir,
sys_fchroot, sys_rename, sys_rmdir, sys_symlink, sys_unlink.
* svr4/dummy.h: Likewise.
* sunos4/syscall.h (sys_chroot, sys_dup, sys_fchdir, sys_fchroot,
sys_rename, sys_rmdir, sys_symlink, sys_unlink): Remove.
* svr4/syscall.h (sys_chroot, sys_dup, sys_fchdir, sys_fchroot,
sys_rename, sys_rmdir, sys_symlink, sys_unlink): Remove.
diff --git a/pathtrace.c b/pathtrace.c
index 380363c..697dfeb 100644
--- a/pathtrace.c
+++ b/pathtrace.c
@@ -195,7 +195,7 @@
s->sys_func == sys_dup3 ||
s->sys_func == sys_sendfile ||
s->sys_func == sys_sendfile64 ||
- !strcmp(s->sys_name, "tee"))
+ s->sys_func == sys_tee)
{
/* fd, fd */
return fdmatch(tcp, tcp->u_arg[0]) ||
@@ -222,9 +222,6 @@
}
if (s->sys_func == sys_link ||
- s->sys_func == sys_pivotroot ||
- s->sys_func == sys_rename ||
- s->sys_func == sys_symlink ||
s->sys_func == sys_mount)
{
/* path, path */
@@ -254,7 +251,7 @@
upathmatch(tcp, tcp->u_arg[2]);
}
- if (!strcmp(s->sys_name, "splice")) {
+ if (s->sys_func == sys_splice) {
/* fd, x, fd, x, x */
return fdmatch(tcp, tcp->u_arg[0]) ||
fdmatch(tcp, tcp->u_arg[2]);