qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Anthony Liguori <anthony@codemonkey.ws>
To: Luiz Capitulino <lcapitulino@redhat.com>
Cc: aliguori@us.ibm.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 5/9] Monitor: Return before exiting with 'quit'
Date: Mon, 26 Apr 2010 13:25:38 -0500	[thread overview]
Message-ID: <4BD5DAA2.4050206@codemonkey.ws> (raw)
In-Reply-To: <20100426152238.5ece1c15@redhat.com>

On 04/26/2010 01:22 PM, Luiz Capitulino wrote:
> On Mon, 26 Apr 2010 12:49:40 -0500
> Anthony Liguori<anthony@codemonkey.ws>  wrote:
>
>    
>> On 04/26/2010 10:47 AM, Luiz Capitulino wrote:
>>      
>>> The 'quit' Monitor command (implemented by do_quit()) calls
>>> exit() directly, this is problematic under QMP because QEMU
>>> exits before having a chance to send the ok response.
>>>
>>> Clients don't know if QEMU exited because of a problem or
>>> because the 'quit' command has been executed.
>>>
>>> This commit fixes that by moving the exit() call to the main
>>> loop, so that do_quit() requests the system to quit, instead
>>> of calling exit() directly.
>>>
>>>        
>> Does this also have the effect of printing out a (qemu) prompt after
>> quit before an EOF appears on that socket?
>>      
>   Ah, right..
>    

It's not necessarily a bad thing if it does.  I just wanted to raise 
that because it's possible that someone depends on the behavior.

I'm not sure it matters to me if we change this behavior though.

>   So, the easiest way to fix this is:
>
> if (user monitor) {
>     exit(0);
> } else {
>     go through main;
> }
>
>   And, wrt to the pull, assuming you like the other patches, what's the best for you?
>    

I'm happy to pull it, just wanted to see fi this issue was considered 
before I did.

Regards,

Anthony Liguori

>   Should I just drop this patch and ask you to pull again or can I do the fix,
> rebase, send it in this thread, and ping you?
>    

  reply	other threads:[~2010-04-26 18:25 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-26 15:47 [Qemu-devel] [PATCH 0/9][PULL]: QMP/Monitor queue Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 1/9] QError: New QERR_QMP_BAD_INPUT_OBJECT_MEMBER Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 2/9] QMP: Use QERR_QMP_BAD_INPUT_OBJECT_MEMBER Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 3/9] QError: Improve QERR_QMP_BAD_INPUT_OBJECT desc Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 4/9] QMP: Check "arguments" member's type Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 5/9] Monitor: Return before exiting with 'quit' Luiz Capitulino
2010-04-26 17:49   ` Anthony Liguori
2010-04-26 18:22     ` Luiz Capitulino
2010-04-26 18:25       ` Anthony Liguori [this message]
2010-04-26 18:53         ` Luiz Capitulino
2010-04-26 19:00           ` Anthony Liguori
2010-04-26 19:10             ` [Qemu-devel] " Jan Kiszka
2010-04-26 19:13               ` Anthony Liguori
2010-04-26 19:44                 ` Luiz Capitulino
2010-04-27 11:52                   ` Paolo Bonzini
2010-04-27 13:20                     ` Luiz Capitulino
2010-04-27 13:52                       ` Paolo Bonzini
2010-04-26 15:47 ` [Qemu-devel] [PATCH 6/9] monitor: Cleanup ID assignment for compat switch Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 7/9] monitor: Reorder intialization to drop initial mux focus Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 8/9] chardev: Document mux option Luiz Capitulino
2010-04-26 15:47 ` [Qemu-devel] [PATCH 9/9] stash away SCM_RIGHTS fd until a getfd command arrives Luiz Capitulino
2010-04-26 21:32 ` [Qemu-devel] [PATCH 0/9][PULL]: QMP/Monitor queue Anthony Liguori

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=4BD5DAA2.4050206@codemonkey.ws \
    --to=anthony@codemonkey.ws \
    --cc=aliguori@us.ibm.com \
    --cc=lcapitulino@redhat.com \
    --cc=qemu-devel@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).