* [PATCH] net: Fix '-net nic,model=' for non-help arguments
@ 2024-08-06 17:21 David Woodhouse
2024-08-11 7:39 ` Michael Tokarev
0 siblings, 1 reply; 3+ messages in thread
From: David Woodhouse @ 2024-08-06 17:21 UTC (permalink / raw)
To: qemu-devel; +Cc: Michael Tokarev, Jason Wang, qemu-stable, Hans
[-- Attachment #1: Type: text/plain, Size: 1025 bytes --]
From: David Woodhouse <dwmw@amazon.co.uk>
Oops, don't *delete* the model option when checking for 'help'.
Fixes: 64f75f57f9d2 ("net: Reinstate '-net nic, model=help' output as documented in man page")
Reported-by: Hans <sungdgdhtryrt@gmail.com>
Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Cc: qemu-stable@nongnu.org
---
This whole mess of alternative command line options could really do
with some self tests. And maybe removing half of them. Three ways of
doing the same thing ought to suffice.
net/net.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/net.c b/net/net.c
index 2eb8bc9c0b..fc1125111c 100644
--- a/net/net.c
+++ b/net/net.c
@@ -1737,7 +1737,7 @@ void net_check_clients(void)
static int net_init_client(void *dummy, QemuOpts *opts, Error **errp)
{
- const char *model = qemu_opt_get_del(opts, "model");
+ const char *model = qemu_opt_get(opts, "model");
if (is_nic_model_help_option(model)) {
return 0;
--
2.44.0
[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5965 bytes --]
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] net: Fix '-net nic,model=' for non-help arguments
2024-08-06 17:21 [PATCH] net: Fix '-net nic,model=' for non-help arguments David Woodhouse
@ 2024-08-11 7:39 ` Michael Tokarev
2024-08-12 7:29 ` Jason Wang
0 siblings, 1 reply; 3+ messages in thread
From: Michael Tokarev @ 2024-08-11 7:39 UTC (permalink / raw)
To: David Woodhouse, qemu-devel
Cc: Jason Wang, qemu-stable, Hans, Richard Henderson
06.08.2024 20:21, David Woodhouse wrote:
> From: David Woodhouse <dwmw@amazon.co.uk>
>
> Oops, don't *delete* the model option when checking for 'help'.
>
> Fixes: 64f75f57f9d2 ("net: Reinstate '-net nic, model=help' output as documented in man page")
> Reported-by: Hans <sungdgdhtryrt@gmail.com>
> Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
> Cc: qemu-stable@nongnu.org
Reviewed-by: Michael Tokarev <mjt@tls.msk.ru>
Please pick this one up to master as a bugfix (Cc'ing rth), or send a pullreq soon :)
Thanks,
/mjt
> ---
> This whole mess of alternative command line options could really do
> with some self tests. And maybe removing half of them. Three ways of
> doing the same thing ought to suffice.
>
> net/net.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/net/net.c b/net/net.c
> index 2eb8bc9c0b..fc1125111c 100644
> --- a/net/net.c
> +++ b/net/net.c
> @@ -1737,7 +1737,7 @@ void net_check_clients(void)
>
> static int net_init_client(void *dummy, QemuOpts *opts, Error **errp)
> {
> - const char *model = qemu_opt_get_del(opts, "model");
> + const char *model = qemu_opt_get(opts, "model");
>
> if (is_nic_model_help_option(model)) {
> return 0;
--
GPG Key transition (from rsa2048 to rsa4096) since 2024-04-24.
New key: rsa4096/61AD3D98ECDF2C8E 9D8B E14E 3F2A 9DD7 9199 28F1 61AD 3D98 ECDF 2C8E
Old key: rsa2048/457CE0A0804465C5 6EE1 95D1 886E 8FFB 810D 4324 457C E0A0 8044 65C5
Transition statement: http://www.corpit.ru/mjt/gpg-transition-2024.txt
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] net: Fix '-net nic,model=' for non-help arguments
2024-08-11 7:39 ` Michael Tokarev
@ 2024-08-12 7:29 ` Jason Wang
0 siblings, 0 replies; 3+ messages in thread
From: Jason Wang @ 2024-08-12 7:29 UTC (permalink / raw)
To: Michael Tokarev
Cc: David Woodhouse, qemu-devel, qemu-stable, Hans, Richard Henderson
On Sun, Aug 11, 2024 at 3:40 PM Michael Tokarev <mjt@tls.msk.ru> wrote:
>
> 06.08.2024 20:21, David Woodhouse wrote:
> > From: David Woodhouse <dwmw@amazon.co.uk>
> >
> > Oops, don't *delete* the model option when checking for 'help'.
> >
> > Fixes: 64f75f57f9d2 ("net: Reinstate '-net nic, model=help' output as documented in man page")
> > Reported-by: Hans <sungdgdhtryrt@gmail.com>
> > Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
> > Cc: qemu-stable@nongnu.org
>
> Reviewed-by: Michael Tokarev <mjt@tls.msk.ru>
>
> Please pick this one up to master as a bugfix (Cc'ing rth), or send a pullreq soon :)
>
> Thanks,
>
> /mjt
I've just sent a pullreq.
Thanks
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-08-12 7:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-06 17:21 [PATCH] net: Fix '-net nic,model=' for non-help arguments David Woodhouse
2024-08-11 7:39 ` Michael Tokarev
2024-08-12 7:29 ` Jason Wang
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).