1 #include "defs.h"
2
3 #include <fcntl.h>
4
5 #ifndef AT_SYMLINK_NOFOLLOW
6 # define AT_SYMLINK_NOFOLLOW 0x100
7 #endif
8 #ifndef AT_REMOVEDIR
9 # define AT_REMOVEDIR 0x200
10 #endif
11 #ifndef AT_SYMLINK_FOLLOW
12 # define AT_SYMLINK_FOLLOW 0x400
13 #endif
14 #ifndef AT_NO_AUTOMOUNT
15 # define AT_NO_AUTOMOUNT 0x800
16 #endif
17 #ifndef AT_EMPTY_PATH
18 # define AT_EMPTY_PATH 0x1000
19 #endif
20
21 #include "xlat/at_flags.h"
22
SYS_FUNC(link)23 SYS_FUNC(link)
24 {
25 if (entering(tcp)) {
26 printpath(tcp, tcp->u_arg[0]);
27 tprints(", ");
28 printpath(tcp, tcp->u_arg[1]);
29 }
30 return 0;
31 }
32
SYS_FUNC(linkat)33 SYS_FUNC(linkat)
34 {
35 if (entering(tcp)) {
36 print_dirfd(tcp, tcp->u_arg[0]);
37 printpath(tcp, tcp->u_arg[1]);
38 tprints(", ");
39 print_dirfd(tcp, tcp->u_arg[2]);
40 printpath(tcp, tcp->u_arg[3]);
41 tprints(", ");
42 printflags(at_flags, tcp->u_arg[4], "AT_???");
43 }
44 return 0;
45 }
46
SYS_FUNC(unlinkat)47 SYS_FUNC(unlinkat)
48 {
49 if (entering(tcp)) {
50 print_dirfd(tcp, tcp->u_arg[0]);
51 printpath(tcp, tcp->u_arg[1]);
52 tprints(", ");
53 printflags(at_flags, tcp->u_arg[2], "AT_???");
54 }
55 return 0;
56 }
57
SYS_FUNC(symlinkat)58 SYS_FUNC(symlinkat)
59 {
60 if (entering(tcp)) {
61 printpath(tcp, tcp->u_arg[0]);
62 tprints(", ");
63 print_dirfd(tcp, tcp->u_arg[1]);
64 printpath(tcp, tcp->u_arg[2]);
65 }
66 return 0;
67 }
68