On 04/26/2010 09:44 PM, Luiz Capitulino wrote:
+    qemu_system_exit_request();

Untested suggestion: why add qemu_system_exit_request, exit_requested, and a hook in the main loop? You can do instead

   no_shutdown = 0;
   qemu_system_shutdown_request();

which will actually call quit_timers() and net_cleanup() properly unlike a blind exit(0).

Alternatively, just give an error when "quit"-ting from QMP and keep the current behavior for non-QMP. This way you do not provide two ways to do the same thing. People will have to avoid -no-shutdown (I don't see how it is useful from QMP) and they will be able to use the "shutdown" monitor command.

Paolo


Reply via email to