Skip to content

Commit

Permalink
attach: use brackets around flag check
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 5, 2021
1 parent f5072dc commit 9475d2b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/lxc/attach.c
Expand Up @@ -1204,7 +1204,8 @@ __noreturn static void do_attach(struct attach_payload *ap)
goto on_error;
}

if (options->attach_flags & LXC_ATTACH_SETGROUPS && options->groups.size > 0) {
if ((options->attach_flags & LXC_ATTACH_SETGROUPS) &&
options->groups.size > 0) {
if (!lxc_setgroups(options->groups.list, options->groups.size))
goto on_error;
} else {
Expand Down

0 comments on commit 9475d2b

Please sign in to comment.