From: "Dr. David Alan Gilbert (git)" <dgilbert@redhat.com>
To: qemu-devel@nongnu.org
Cc: amit.shah@redhat.com, stefanha@redhat.com, quintela@redhat.com
Subject: [Qemu-devel] [PATCH 3/3] Print errors in some of the early migration failure cases.
Date: Tue, 20 Jan 2015 14:48:03 +0000 [thread overview]
Message-ID: <1421765283-17822-4-git-send-email-dgilbert@redhat.com> (raw)
In-Reply-To: <1421765283-17822-1-git-send-email-dgilbert@redhat.com>
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
---
savevm.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/savevm.c b/savevm.c
index 1cc0f02..98895fe 100644
--- a/savevm.c
+++ b/savevm.c
@@ -883,16 +883,20 @@ int qemu_loadvm_state(QEMUFile *f)
QLIST_HEAD(, LoadStateEntry) loadvm_handlers =
QLIST_HEAD_INITIALIZER(loadvm_handlers);
LoadStateEntry *le, *new_le;
+ Error *local_err = NULL;
uint8_t section_type;
unsigned int v;
int ret;
- if (qemu_savevm_state_blocked(NULL)) {
+ if (qemu_savevm_state_blocked(&local_err)) {
+ error_report("%s", error_get_pretty(local_err));
+ error_free(local_err);
return -EINVAL;
}
v = qemu_get_be32(f);
if (v != QEMU_VM_FILE_MAGIC) {
+ error_report("Not a migration stream");
return -EINVAL;
}
@@ -902,6 +906,7 @@ int qemu_loadvm_state(QEMUFile *f)
return -ENOTSUP;
}
if (v != QEMU_VM_FILE_VERSION) {
+ error_report("Unsupported migration stream version");
return -ENOTSUP;
}
--
2.1.0
next prev parent reply other threads:[~2015-01-20 14:48 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-20 14:48 [Qemu-devel] [PATCH 0/3] Migration tracing and errors Dr. David Alan Gilbert (git)
2015-01-20 14:48 ` [Qemu-devel] [PATCH 1/3] savevm: Convert fprintf to error_report Dr. David Alan Gilbert (git)
2015-01-21 5:56 ` Amit Shah
2015-01-20 14:48 ` [Qemu-devel] [PATCH 2/3] Migration: Add lots of trace events Dr. David Alan Gilbert (git)
2015-01-21 6:02 ` Amit Shah
2015-01-21 9:19 ` Dr. David Alan Gilbert
2015-01-20 14:48 ` Dr. David Alan Gilbert (git) [this message]
2015-01-21 6:03 ` [Qemu-devel] [PATCH 3/3] Print errors in some of the early migration failure cases Amit Shah
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=1421765283-17822-4-git-send-email-dgilbert@redhat.com \
--to=dgilbert@redhat.com \
--cc=amit.shah@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=quintela@redhat.com \
--cc=stefanha@redhat.com \
/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).