]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
confile: config_autodev()
authorChristian Brauner <christian.brauner@ubuntu.com>
Tue, 30 May 2017 02:44:48 +0000 (04:44 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Tue, 30 May 2017 16:43:05 +0000 (18:43 +0200)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/confile.c

index 92714968ce28679f1e0c4c261d91f3946070662f..767b1e327a0fdffbd65849c05439928af560a0ef 100644 (file)
@@ -1512,9 +1512,13 @@ static int config_loglevel(const char *key, const char *value,
 static int config_autodev(const char *key, const char *value,
                          struct lxc_conf *lxc_conf)
 {
-       if (config_value_empty(value))
+       /* Set config value to default. */
+       if (config_value_empty(value)) {
+               lxc_conf->autodev = 0;
                return 0;
+       }
 
+       /* Parse new config value. */
        if (lxc_safe_uint(value, &lxc_conf->autodev) < 0)
                return -1;