[cups.development] Character conversion issue in templates
Michael Sweet
msweet at apple.com
Tue Feb 22 10:49:44 PST 2011
On Feb 22, 2011, at 6:34 AM, Ozan Çağlayan wrote:
> Hi,
>
> When the preferred language is Turkish in the browser (tested with Chrome and Firefox), the templates
> the CUPS web interface are not correctly handled as in Turkish toupper() and tolower() behaves differently
> if the LC_CTYPE is set to tr_TR.UTF-8.
>
> (In Turkish, the uppercase of lower 'i' is not 'I' but 'İ' (with a dot above), and vice versa.)
>
> The patch below fixes the problem by locale-independently converting the cases.
>
> The result of the problem is that the {title} and {device_uri} templates are not replaced by
> their values.
>
> If you think that this is the correct fix or this should be fixed in CUPS, I can create a ticket
> with the full patch attached.
Please file a bug here:
http://www.cups.org/str.php
While your suggested patch is not safe for a library, we can simply provide our own toupper/tolower implementation like we do for some of the other problematic ctype macros.
__________________________________________________
Michael Sweet, Senior Printing System Engineer, PWG Chair
More information about the cups
mailing list