[glib] gapplication(1): print GVariant errors in context
- From: Ryan Lortie <desrt src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib] gapplication(1): print GVariant errors in context
- Date: Sun, 22 Dec 2013 16:42:12 +0000 (UTC)
commit 94a89f6c2fdbffe562a0ec34a979c01fefc5a9ac
Author: Ryan Lortie <desrt desrt ca>
Date: Fri Nov 22 12:57:21 2013 -0500
gapplication(1): print GVariant errors in context
Use g_variant_parse_error_print_context() to format the error message
from the GVariant parser.
https://bugzilla.gnome.org/show_bug.cgi?id=715028
gio/gapplication-tool.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/gio/gapplication-tool.c b/gio/gapplication-tool.c
index c152909..11fdce0 100644
--- a/gio/gapplication-tool.c
+++ b/gio/gapplication-tool.c
@@ -336,9 +336,13 @@ app_action (gchar **args)
if (!parameter)
{
- g_printerr (_("error parsing action parameter: %s\n"), error->message);
+ gchar *context;
+
+ context = g_variant_parse_error_print_context (error, args[2]);
+ g_printerr (_("error parsing action parameter: %s\n"), context);
g_variant_builder_clear (¶ms);
g_error_free (error);
+ g_free (context);
return 1;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]