fix warning
don't mangle first character if non-ASCII
This commit is contained in:
@@ -965,7 +965,9 @@ CString Capitalize( const CString &s )
|
|||||||
if( s.GetLength()==0 )
|
if( s.GetLength()==0 )
|
||||||
return "";
|
return "";
|
||||||
CString s2 = s;
|
CString s2 = s;
|
||||||
s2[0] = toupper( s2[0] );
|
/* XXX: utf-8 */
|
||||||
|
if( s2[0] <= 127 )
|
||||||
|
s2[0] = (char) toupper( s2[0] );
|
||||||
return s2;
|
return s2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user