All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bandan Das <bsd@redhat.com>
To: qemu-devel@nongnu.org
Cc: armbru@redhat.com
Subject: [Qemu-devel] [PATCH v3 2/2] When a command fails due to incorrect syntax or input, suggest using the "help" command to get more information about the command. This is only applicable for HMP.
Date: Wed, 27 May 2015 19:19:14 -0400	[thread overview]
Message-ID: <1432768754-28523-3-git-send-email-bsd@redhat.com> (raw)
In-Reply-To: <1432768754-28523-1-git-send-email-bsd@redhat.com>

Before:
(qemu) drive_add usb_flash_drive
drive_add: string expected
After:
(qemu) drive_add usb_flash_drive
drive_add: string expected
Try "help drive_add" for more information

Reviewed-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Bandan Das <bsd@redhat.com>
---
 monitor.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/monitor.c b/monitor.c
index 521258d..2ed9fb7 100644
--- a/monitor.c
+++ b/monitor.c
@@ -4134,6 +4134,8 @@ static void handle_user_command(Monitor *mon, const char *cmdline)
 
     qdict = monitor_parse_arguments(mon, &cmdline, cmd);
     if (!qdict) {
+        monitor_printf(mon, "Try \"help %s\" for more information\n",
+                       cmd->name);
         return;
     }
 
-- 
2.1.0

      parent reply	other threads:[~2015-05-27 23:19 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-27 23:19 [Qemu-devel] [PATCH v3 0/2] monitor: suggest running "help" for command errors Bandan Das
2015-05-27 23:19 ` [Qemu-devel] [PATCH v3 1/2] monitor: cleanup parsing of cmd name and cmd arguments Bandan Das
2015-05-28  7:17   ` Markus Armbruster
2015-05-28 18:48     ` Bandan Das
2015-05-28 19:48       ` Eric Blake
2015-05-28 20:24         ` Bandan Das
2015-05-29  7:57           ` Markus Armbruster
2015-05-27 23:19 ` Bandan Das [this message]

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=1432768754-28523-3-git-send-email-bsd@redhat.com \
    --to=bsd@redhat.com \
    --cc=armbru@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.