diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2014-11-23 20:01:40 -0500 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2014-11-24 10:20:53 -0500 |
commit | 8086ffacdb1bfec5ec115d24626538bda6cc372e (patch) | |
tree | 616defdc8b87ccd677f8a75f9eca72706a1a769c | |
parent | 9a20fcbcd1b010ad88bfbb8b7f0417bec7327fb4 (diff) |
gpt-auto-generator: properly ignore value
A negative return code was treated as a true value.
-rw-r--r-- | src/gpt-auto-generator/gpt-auto-generator.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gpt-auto-generator/gpt-auto-generator.c b/src/gpt-auto-generator/gpt-auto-generator.c index d4cfe37298..9251ddff75 100644 --- a/src/gpt-auto-generator/gpt-auto-generator.c +++ b/src/gpt-auto-generator/gpt-auto-generator.c @@ -680,8 +680,8 @@ static int parse_proc_cmdline_item(const char *key, const char *value) { r = parse_boolean(value); if (r < 0) log_warning("Failed to parse gpt-auto switch %s. Ignoring.", value); - - arg_enabled = r; + else + arg_enabled = r; } else if (streq(key, "root") && value) { |