|
|
9ae3a8 |
From 99421ce09cafb7fccd0d3db0144210ba16f40718 Mon Sep 17 00:00:00 2001
|
|
|
9ae3a8 |
From: Gerd Hoffmann <kraxel@redhat.com>
|
|
|
9ae3a8 |
Date: Mon, 14 Oct 2013 13:35:12 +0200
|
|
|
9ae3a8 |
Subject: [PATCH 05/18] qemu-char: check optional fields using has_*
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
RH-Author: Gerd Hoffmann <kraxel@redhat.com>
|
|
|
9ae3a8 |
Message-id: <1381757723-23134-5-git-send-email-kraxel@redhat.com>
|
|
|
9ae3a8 |
Patchwork-id: 54850
|
|
|
9ae3a8 |
O-Subject: [RHEL-7 qemu-kvm PATCH 04/15] qemu-char: check optional fields using has_*
|
|
|
9ae3a8 |
Bugzilla: 922010
|
|
|
9ae3a8 |
RH-Acked-by: Hans de Goede <hdegoede@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
|
9ae3a8 |
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
|
|
|
9ae3a8 |
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
|
|
|
9ae3a8 |
(cherry picked from commit e859eda58501cd20a2e6988fb4acc1756bc4d278)
|
|
|
9ae3a8 |
---
|
|
|
9ae3a8 |
qemu-char.c | 4 ++--
|
|
|
9ae3a8 |
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
9ae3a8 |
---
|
|
|
9ae3a8 |
qemu-char.c | 4 ++--
|
|
|
9ae3a8 |
1 files changed, 2 insertions(+), 2 deletions(-)
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
diff --git a/qemu-char.c b/qemu-char.c
|
|
|
9ae3a8 |
index 660d758..ddc3dca 100644
|
|
|
9ae3a8 |
--- a/qemu-char.c
|
|
|
9ae3a8 |
+++ b/qemu-char.c
|
|
|
9ae3a8 |
@@ -3521,7 +3521,7 @@ static CharDriverState *qmp_chardev_open_file(ChardevFile *file, Error **errp)
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
HANDLE out;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- if (file->in) {
|
|
|
9ae3a8 |
+ if (file->has_in) {
|
|
|
9ae3a8 |
error_setg(errp, "input file not supported");
|
|
|
9ae3a8 |
return NULL;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
@@ -3572,7 +3572,7 @@ static CharDriverState *qmp_chardev_open_file(ChardevFile *file, Error **errp)
|
|
|
9ae3a8 |
return NULL;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- if (file->in) {
|
|
|
9ae3a8 |
+ if (file->has_in) {
|
|
|
9ae3a8 |
flags = O_RDONLY;
|
|
|
9ae3a8 |
in = qmp_chardev_open_file_source(file->in, flags, errp);
|
|
|
9ae3a8 |
if (error_is_set(errp)) {
|
|
|
9ae3a8 |
--
|
|
|
9ae3a8 |
1.7.1
|
|
|
9ae3a8 |
|