On Sat, 9 Sep 2000, Aleksander Salwa wrote:
> Some time ago I had a problem with locales on FreeBSD.
> Finally, I solved it by patching Splitter.c.
> I added casting of values passed to funtions isalpha, isalnum to
> type 'unsigned char'. They are declared in Splitter.c as 'char'.
> On all machines I'm working on, 'char' is signed.
> On Linux/x86, isalpha and others works fine with positive and negative
> values of national characters. (For example, one polish character is
> '\xc6', what can be evaluated as unsigned 198, or signed -58.)
> But on FreeBSD/x86 these functions work only with values >127.
> Because 'char' is signed, it needs casting to work with national
> characters.
> Now, the question is: is it a bug in Splitter.c or in FreeBSD system
> libraries ? (or misconfigured system)

   It is bug in Linux libraries! They tricked you to think it is right way,
but it is actually wrong way. FreeBSD (in this aspect) is better, more
strict (there are aspect where Linux clearly wins :).
   Compile Zope with gcc -funsigned-char on FreeBSD.

     Oleg Broytmann            http://phd.pp.ru/            [EMAIL PROTECTED]
           Programmers don't die, they just GOSUB without RETURN.

Zope maillist  -  [EMAIL PROTECTED]
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to