qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 1/2] fix a typo of strict option


From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH v2 1/2] fix a typo of strict option
Date: Mon, 09 Dec 2013 10:16:38 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

Amos Kong <address@hidden> writes:

> The type of "strict" should be bool.
>
> Signed-off-by: Amos Kong <address@hidden>
> ---
>  vl.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/vl.c b/vl.c
> index b0399de..12fe1f7 100644
> --- a/vl.c
> +++ b/vl.c
> @@ -461,7 +461,7 @@ static QemuOptsList qemu_boot_opts = {
>              .type = QEMU_OPT_STRING,
>          }, {
>              .name = "strict",
> -            .type = QEMU_OPT_STRING,
> +            .type = QEMU_OPT_BOOL,
>          },
>          { /*End of list */ }
>      },

No, this isn't just a typo fix, it's an interface change.  It's not
immediately obvious whether it's okay.

-boot parameter 'strict' appeared in commit c8a6ae8.  It was declared
QEMU_OPT_STRING, but the code using the value rejected anything but 'on'
and 'off'.  This shipped in 1.5.0.

Commit 6ef4716 accidentally dropped the code using the value of
'strict'.  Since then, any parameter value is accepted and silently
ignored.  Shipped in 1.6.0.

Your change restores the "reject anything but 'on' and 'off'" part (the
"use the value" part gets restored in the next patch).  Okay, because
the values erroneously accepted in the meantime didn't do anything.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]