Skip to content

Commit

Permalink
bpf: align struct initialization
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
  • Loading branch information
Christian Brauner committed Feb 26, 2021
1 parent e490acc commit 54c17d3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/lxc/cgroups/cgroup2_devices.c
Expand Up @@ -425,9 +425,9 @@ int bpf_program_cgroup_detach(struct bpf_program *prog)
return 0;

attr = &(union bpf_attr){
.attach_type = prog->attached_type,
.target_fd = prog->fd_cgroup,
.attach_bpf_fd = prog->kernel_fd,
.attach_type = prog->attached_type,
.target_fd = prog->fd_cgroup,
.attach_bpf_fd = prog->kernel_fd,
};

ret = bpf(BPF_PROG_DETACH, attr, sizeof(*attr));
Expand Down

0 comments on commit 54c17d3

Please sign in to comment.