[2/2] comctl32: replace nonprintable characters with spaces on SB_SETTEXT

Nikolay Sivov bunglehead at gmail.com
Tue Mar 3 13:36:26 CST 2009


Alexandre Julliard wrote:
> Nikolay Sivov <bunglehead at gmail.com> writes:
>
>   
>> @@ -775,6 +777,16 @@ STATUSBAR_SetTextT (STATUS_INFO *infoPtr, INT nPart, WORD style,
>>  	    strcpyW (ntext, text);
>>  	} else ntext = 0;
>>  
>> +	/* replace nonprintable characters with spaces */
>> +	if (ntext) {
>> +	    idx = ntext;
>> +	    while (*idx) {
>> +	        if(!isprintW(*idx))
>> +	            *idx = space;
>> +	        idx++;
>>     
>
> This would need some test cases with various invalid chars to confirm
> that isprintW is the right check to use.
>   
Sure, will make it soon.



More information about the wine-devel mailing list