[gtk+] composetable: Don't abort on unsupported escape sequences
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] composetable: Don't abort on unsupported escape sequences
- Date: Thu, 28 Jan 2016 04:23:22 +0000 (UTC)
commit 03f4666994a72d72551cae31efb946aa742addca
Author: Matthias Clasen <mclasen redhat com>
Date: Wed Jan 27 23:22:02 2016 -0500
composetable: Don't abort on unsupported escape sequences
People might put all sorts of gunk in their .XCompose file, in
the hope that XLib makes sense of it. Even if we don't make sense
of it, we shouldn't abort, but instead ignore the lines we can't
understand. Pointed out in
https://bugzilla.redhat.com/show_bug.cgi?id=1301254
gtk/gtkcomposetable.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkcomposetable.c b/gtk/gtkcomposetable.c
index eaff054..9b4cb15 100644
--- a/gtk/gtkcomposetable.c
+++ b/gtk/gtkcomposetable.c
@@ -104,7 +104,9 @@ parse_compose_value (GtkComposeData *compose_data,
uch = g_ascii_strtoll(words[1] + 1, NULL, 8);
/* If we need to handle other escape sequences. */
else if (uch != '\\')
- g_assert_not_reached ();
+ {
+ g_warning ("Invalid escape sequence: %s: %s", val, line);
+ }
}
if (g_utf8_get_char (g_utf8_next_char (words[1])) > 0)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]