[gnome-builder] libide: check for printable char in tracing macro
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] libide: check for printable char in tracing macro
- Date: Mon, 23 Mar 2015 23:53:06 +0000 (UTC)
commit 4df30cf2cffc757674e96bd0866554eaf5470b60
Author: Christian Hergert <christian hergert me>
Date: Wed Mar 4 02:03:54 2015 -0800
libide: check for printable char in tracing macro
libide/ide-source-view.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/libide/ide-source-view.c b/libide/ide-source-view.c
index bd80247..48ae765 100644
--- a/libide/ide-source-view.c
+++ b/libide/ide-source-view.c
@@ -1194,11 +1194,14 @@ ide_source_view_key_press_event (GtkWidget *widget,
#ifndef IDE_DISABLE_TRACE
{
+ gunichar ch = 0;
gchar *name = NULL;
g_object_get (priv->mode, "name", &name, NULL);
+ if (event->string)
+ ch = g_utf8_get_char (event->string);
IDE_TRACE_MSG ("dispatching to mode \"%s\": (%s)",
- name, event->string ?: "");
+ name, g_unichar_isprint (ch) ? event->string : "");
g_free (name);
}
#endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]