Skip to content

Commit

Permalink
commands_utils: indicate taking ownership of state_client_fd in
Browse files Browse the repository at this point in the history
lxc_add_state_client()

Signed-off-by: Matthias Hardt <matthias.hardt@gmail.com>
  • Loading branch information
Piscolero committed Mar 9, 2020
1 parent d7aa555 commit cd0dc36
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/lxc/commands_utils.c
Expand Up @@ -171,7 +171,7 @@ int lxc_cmd_connect(const char *name, const char *lxcpath,
return client_fd;
}

int lxc_add_state_client(int state_client_fd, struct lxc_handler *handler,
int lxc_add_state_client(__owns int state_client_fd, struct lxc_handler *handler,
lxc_state_t states[MAX_STATE])
{
__do_free struct lxc_state_client *newclient = NULL;
Expand Down
3 changes: 3 additions & 0 deletions src/lxc/compiler.h
Expand Up @@ -52,6 +52,9 @@
#define __lxc_unused
#endif

/* Indicates taking ownership */
#define __owns

#define __cgfsng_ops

#endif /* __LXC_COMPILER_H */

0 comments on commit cd0dc36

Please sign in to comment.