From: Thomas Huth <thuth@redhat.com>
To: Michal Privoznik <mprivozn@redhat.com>, qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org, pbonzini@redhat.com
Subject: Re: [Qemu-trivial] [Qemu-devel] [PATCH] qemu-options: Allow -no-user-config again
Date: Mon, 14 May 2018 16:43:01 +0200 [thread overview]
Message-ID: <9ff0bc35-8996-599a-9478-07f6e1e54596@redhat.com> (raw)
In-Reply-To: <9dbde2b5d864d126b75d8c0d7bae2011e8cc7e9b.1526305502.git.mprivozn@redhat.com>
On 14.05.2018 15:45, Michal Privoznik wrote:
> After 1217d6ca2bf28c0febe1bd7d5b3fa912bbf6af2a we error out
> explicitly if an unknown -option was passed on the command line.
> However, we are doing two pass command line option parsing. In
> the first pass we just look for -no-user-config or -nodefconfig
> being present which determines whether we load user config or
> not. Then in the second pass we finally parse everything else
> throwing an error if an unsupported -option was found. Problem is
> that in the second pass -no-user-config and -nodefconfig are not
> handled explicitly which makes us throw the unsupported option
> error.
>
> Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
> ---
> vl.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/vl.c b/vl.c
> index b9f6b42779..846cd29d8a 100644
> --- a/vl.c
> +++ b/vl.c
> @@ -4015,6 +4015,10 @@ int main(int argc, char **argv, char **envp)
> exit(1);
> }
> break;
> + case QEMU_OPTION_nodefconfig:
> + case QEMU_OPTION_nouserconfig:
> + /* Nothing to be parsed here. Especially, do not error out below. */
> + break;
> default:
> if (os_parse_cmd_args(popt->index, optarg)) {
> error_report("Option not supported in this build");
>
Reviewed-by: Thomas Huth <thuth@redhat.com>
next prev parent reply other threads:[~2018-05-14 14:43 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-14 13:45 [Qemu-trivial] [PATCH] qemu-options: Allow -no-user-config again Michal Privoznik
2018-05-14 14:43 ` Thomas Huth [this message]
2018-05-14 17:26 ` [Qemu-trivial] [Qemu-devel] " Marc-André Lureau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9ff0bc35-8996-599a-9478-07f6e1e54596@redhat.com \
--to=thuth@redhat.com \
--cc=mprivozn@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).