blob: f28f69d78d290ef63a008692f9dec31dda7a766f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
#include "defs.h"
#include <fcntl.h>
#include "xlat/access_flags.h"
static int
decode_access(struct tcb *tcp, int offset)
{
if (entering(tcp)) {
printpath(tcp, tcp->u_arg[offset]);
tprints(", ");
printflags(access_flags, tcp->u_arg[offset + 1], "?_OK");
}
return 0;
}
int
sys_access(struct tcb *tcp)
{
return decode_access(tcp, 0);
}
int
sys_faccessat(struct tcb *tcp)
{
if (entering(tcp))
print_dirfd(tcp, tcp->u_arg[0]);
return decode_access(tcp, 1);
}
|