From d680cc1f2f49062043ef340e3c374cc28d8eb6b0 Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Sat, 3 Jan 2004 04:30:34 +0000 Subject: [PATCH] fix warning don't mangle first character if non-ASCII --- stepmania/src/RageUtil.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/stepmania/src/RageUtil.cpp b/stepmania/src/RageUtil.cpp index 094869a5f5..cb8a0ca2fe 100644 --- a/stepmania/src/RageUtil.cpp +++ b/stepmania/src/RageUtil.cpp @@ -965,7 +965,9 @@ CString Capitalize( const CString &s ) if( s.GetLength()==0 ) return ""; CString s2 = s; - s2[0] = toupper( s2[0] ); + /* XXX: utf-8 */ + if( s2[0] <= 127 ) + s2[0] = (char) toupper( s2[0] ); return s2; }