diff -ru tcsh-6.17.02_orig/tc.str.c tcsh-6.17.02/tc.str.c
--- tcsh-6.17.02_orig/tc.str.c	2010-05-07 18:39:44.000000000 +0200
+++ tcsh-6.17.02/tc.str.c	2010-11-30 19:54:45.000000000 +0100
@@ -104,8 +104,9 @@
 
     memset (&mb, 0, sizeof mb);
     ret = mbrtowc(&tmp, s, n, &mb);
-    if (ret > 0) {
+    if (ret >= 0)
 	*pwc = tmp;
+    if (ret > 0) {
 #ifdef UTF16_STRINGS
 	if (tmp >= 0xd800 && tmp <= 0xdbff) {
 	    /* UTF-16 surrogate pair.  Fetch second half and compute
