[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v7 38/39] hmp: Add read-only-mode option to chan
From: |
Kevin Wolf |
Subject: |
Re: [Qemu-devel] [PATCH v7 38/39] hmp: Add read-only-mode option to change command |
Date: |
Mon, 26 Oct 2015 13:12:54 +0100 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Am 19.10.2015 um 17:53 hat Max Reitz geschrieben:
> Expose the new read-only-mode option of 'blockdev-change-medium' for the
> 'change' HMP command.
>
> Signed-off-by: Max Reitz <address@hidden>
> Reviewed-by: Eric Blake <address@hidden>
> @@ -1336,9 +1337,16 @@ void hmp_change(Monitor *mon, const QDict *qdict)
> const char *device = qdict_get_str(qdict, "device");
> const char *target = qdict_get_str(qdict, "target");
> const char *arg = qdict_get_try_str(qdict, "arg");
> + const char *read_only = qdict_get_try_str(qdict, "read-only-mode");
> + BlockdevChangeReadOnlyMode read_only_mode = 0;
> Error *err = NULL;
>
> if (strcmp(device, "vnc") == 0) {
> + if (read_only) {
> + monitor_printf(mon,
> + "Parameter 'read-only-mode' is invalid for VNC");
Missing \n.
> + return;
> + }
> if (strcmp(target, "passwd") == 0 ||
> strcmp(target, "password") == 0) {
> if (!arg) {
With that fixed:
Reviewed-by: Kevin Wolf <address@hidden>
- Re: [Qemu-devel] [PATCH v7 34/39] block: Inquire tray state before tray-moved events, (continued)
- [Qemu-devel] [PATCH v7 35/39] qmp: Introduce blockdev-change-medium, Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v7 37/39] blockdev: read-only-mode for blockdev-change-medium, Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v7 36/39] hmp: Use blockdev-change-medium for change command, Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v7 38/39] hmp: Add read-only-mode option to change command, Max Reitz, 2015/10/19
- Re: [Qemu-devel] [PATCH v7 38/39] hmp: Add read-only-mode option to change command,
Kevin Wolf <=
- [Qemu-devel] [PATCH v7 39/39] iotests: Add test for change-related QMP commands, Max Reitz, 2015/10/19
- Re: [Qemu-devel] [PATCH v7 00/39] blockdev: BlockBackend and media, Kevin Wolf, 2015/10/20