On 08.07.2022 18:19, Andrew Cooper wrote:
> This will help parsing a sub-option which has boolean and non-boolean options
> available.
> 
> First, rework 'int val' into 'bool has_neg_prefix'.  This inverts it's value,
> but the resulting logic is far easier to follow.
> 
> Second, reject anything of the form 'no-$FOO=' which excludes ambiguous
> constructs such as 'no-$foo=yes' which have never been valid.
> 
> This just leaves the case where everything is otherwise fine, but parse_bool()
> can't interpret the provided string.
> 
> Signed-off-by: Andrew Cooper <andrew.coop...@citrix.com>

Reviewed-by: Jan Beulich <jbeul...@suse.com>


Reply via email to