From: Michael Roth <mdroth@linux.vnet.ibm.com>
To: qemu-devel@nongnu.org
Cc: peter.maydell@linaro.org,
"Marc-André Lureau" <marcandre.lureau@redhat.com>
Subject: [Qemu-devel] [PULL 5/8] qga: report error on keyfile dump error
Date: Tue, 18 Jul 2017 00:20:13 -0500 [thread overview]
Message-ID: <1500355216-23603-6-git-send-email-mdroth@linux.vnet.ibm.com> (raw)
In-Reply-To: <1500355216-23603-1-git-send-email-mdroth@linux.vnet.ibm.com>
From: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Cc:qemu-trivial@nongnu.org
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
---
qga/main.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/qga/main.c b/qga/main.c
index dcd6104..1b381d0 100644
--- a/qga/main.c
+++ b/qga/main.c
@@ -1074,7 +1074,12 @@ static void config_dump(GAConfig *config)
g_free(tmp);
tmp = g_key_file_to_data(keyfile, NULL, &error);
- printf("%s", tmp);
+ if (error) {
+ g_critical("Failed to dump keyfile: %s", error->message);
+ g_clear_error(&error);
+ } else {
+ printf("%s", tmp);
+ }
g_free(tmp);
g_key_file_free(keyfile);
--
2.7.4
next prev parent reply other threads:[~2017-07-18 5:21 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-18 5:20 [Qemu-devel] [PULL 0/8] qemu-ga patch queue Michael Roth
2017-07-18 5:20 ` [Qemu-devel] [PULL 1/8] qga-win: fix installation on localized windows Michael Roth
2017-07-18 5:20 ` [Qemu-devel] [PULL 2/8] qemu-ga: add missing libpcre to MSI build Michael Roth
2017-07-18 5:20 ` [Qemu-devel] [PULL 3/8] qemu-ga: check if utmpx.h is available on the system Michael Roth
2017-07-18 5:20 ` [Qemu-devel] [PULL 4/8] qga-win32: remove a redundancy code Michael Roth
2017-07-18 5:20 ` Michael Roth [this message]
2017-07-18 5:20 ` [Qemu-devel] [PULL 6/8] qemu-ga: add guest-get-osinfo command Michael Roth
2017-07-18 5:20 ` [Qemu-devel] [PULL 7/8] test-qga: pass environemnt to qemu-ga Michael Roth
2017-07-18 5:20 ` [Qemu-devel] [PULL 8/8] test-qga: add test for guest-get-osinfo Michael Roth
2017-07-18 11:01 ` [Qemu-devel] [PULL 0/8] qemu-ga patch queue Michael Roth
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=1500355216-23603-6-git-send-email-mdroth@linux.vnet.ibm.com \
--to=mdroth@linux.vnet.ibm.com \
--cc=marcandre.lureau@redhat.com \
--cc=peter.maydell@linaro.org \
--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 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).