]> git.proxmox.com Git - mirror_lxc.git/commit - src/lxc/lxccontainer.c
lxccontainer: add lxc_config_item_is_supported()
authorChristian Brauner <christian.brauner@ubuntu.com>
Wed, 3 May 2017 10:12:22 +0000 (12:12 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Wed, 3 May 2017 10:12:22 +0000 (12:12 +0200)
commit12461428889932e8918553a111bbedaf8fce2db6
tree3d84952b590925ed6c2d18c8964d28211c31802f
parent2c0807c7c4ae01cf54c204c1a05ef6a736560d7c
lxccontainer: add lxc_config_item_is_supported()

This adds lxc_config_item_is_supported() as API extension. It allows to check
whether a given config item (e.g. lxc.autodev) is supported by this LXC
instance. The function is useful in the following scenarios:
1. Users have compiled liblxc from source and have removed a config items from
   the corresponding struct in confile.c. (For example, embedded users might
   decide to gut a bunch of options that they cannot use.)
2. Callers that want to check for a specific configuration item independent of
   the version numbers exposed in our version.h header.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/lxccontainer.c
src/lxc/lxccontainer.h