#include "xlat/cap_version.h"
-typedef struct user_cap_header_struct {
+struct user_cap_header_struct {
uint32_t version;
int pid;
-} *cap_user_header_t;
+};
-typedef struct user_cap_data_struct {
+struct user_cap_data_struct {
uint32_t effective;
uint32_t permitted;
uint32_t inheritable;
-} *cap_user_data_t;
+};
-static cap_user_header_t
+static const struct user_cap_header_struct *
get_cap_header(struct tcb *const tcp, const kernel_ulong_t addr)
{
static struct user_cap_header_struct header;
static void
print_cap_header(struct tcb *const tcp, const kernel_ulong_t addr,
- const cap_user_header_t const h)
+ const struct user_cap_header_struct *const h)
{
if (!addr || !h) {
printaddr(addr);
static void
print_cap_data(struct tcb *const tcp, const kernel_ulong_t addr,
- const cap_user_header_t const h)
+ const struct user_cap_header_struct *const h)
{
struct user_cap_data_struct data[2];
unsigned int len;
SYS_FUNC(capget)
{
- cap_user_header_t h;
+ const struct user_cap_header_struct *h;
if (entering(tcp)) {
h = get_cap_header(tcp, tcp->u_arg[0]);
SYS_FUNC(capset)
{
- cap_user_header_t h = get_cap_header(tcp, tcp->u_arg[0]);
+ const struct user_cap_header_struct *const h =
+ get_cap_header(tcp, tcp->u_arg[0]);
print_cap_header(tcp, tcp->u_arg[0], h);
tprints(", ");
print_cap_data(tcp, tcp->u_arg[1], h);