Commit 623602cb7804c2cdc8ac872069c6e1186636c934

Ran Benita 2014-02-07T01:35:56

test: don't print control characters in interactive tests Signed-off-by: Ran Benita <ran234@gmail.com>

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/test/common.c b/test/common.c
index 5fe6ece..fd013ca 100644
--- a/test/common.c
+++ b/test/common.c
@@ -379,7 +379,7 @@ test_print_keycode_state(struct xkb_state *state, xkb_keycode_t keycode)
     printf("unicode [ ");
     for (int i = 0; i < nsyms; i++) {
         uint32_t unicode = xkb_keysym_to_utf32(syms[i]);
-        printf("%lc ", (int)(unicode ? unicode : L' '));
+        printf("%lc ", (int) (unicode > 32 ? unicode : L' '));
     }
     printf("] ");
 #endif