changeset 55:5ec3b7d14715

Add typecasts to fix printing of 8-bit characters.
author Matti Hamalainen <ccr@tnsp.org>
date Tue, 11 Nov 2008 10:53:15 +0200
parents f6666e7c1a48
children 7b9049defee3
files nnchat.c
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/nnchat.c	Mon Nov 10 08:32:49 2008 +0200
+++ b/nnchat.c	Tue Nov 11 10:53:15 2008 +0200
@@ -433,7 +433,7 @@
 			int val = 0;
 			s++;
 			if (*s == '½') {
-				waddch(win, *s | col);
+				waddch(win, ((unsigned char) *s) | col);
 				s++;
 			} else {
 				while (*s && isdigit(*s)) {
@@ -451,7 +451,7 @@
 				}
 			}
 		} else {
-			waddch(win, *s | col);
+			waddch(win, ((unsigned char) *s) | col);
 			s++;
 		}
 	}