[patch] glib20, UTF-8 and string collation

2008-01-09 Thread Alexandre Sunny Kovalenko
I have seen recent commit WRT string collation in devel/glib20 by marcus, so I have decided to check if there is an interest to fix SEGV in g_utf8_collate when it is given 8-bit non-UTF-8 string(s) to collate. Good (but by no means only) example of this would be using Evolution to open mailbox

Re: [patch] glib20, UTF-8 and string collation

2008-01-09 Thread Joe Marcus Clarke
On Wed, 2008-01-09 at 10:53 -0500, Alexandre Sunny Kovalenko wrote: I have seen recent commit WRT string collation in devel/glib20 by marcus, so I have decided to check if there is an interest to fix SEGV in g_utf8_collate when it is given 8-bit non-UTF-8 string(s) to collate. Any commits I

Re: [patch] glib20, UTF-8 and string collation

2008-01-09 Thread Alexandre Sunny Kovalenko
On Wed, 2008-01-09 at 12:35 -0500, Joe Marcus Clarke wrote: On Wed, 2008-01-09 at 10:53 -0500, Alexandre Sunny Kovalenko wrote: I have seen recent commit WRT string collation in devel/glib20 by marcus, so I have decided to check if there is an interest to fix SEGV in g_utf8_collate when

Re: [patch] glib20, UTF-8 and string collation

2008-01-09 Thread Joe Marcus Clarke
On Wed, 2008-01-09 at 19:40 -0500, Alexandre Sunny Kovalenko wrote: On Wed, 2008-01-09 at 12:35 -0500, Joe Marcus Clarke wrote: On Wed, 2008-01-09 at 10:53 -0500, Alexandre Sunny Kovalenko wrote: I have seen recent commit WRT string collation in devel/glib20 by marcus, so I have decided

Re: [patch] glib20, UTF-8 and string collation

2008-01-09 Thread Alexandre Sunny Kovalenko
On Wed, 2008-01-09 at 20:16 -0500, Joe Marcus Clarke wrote: On Wed, 2008-01-09 at 19:40 -0500, Alexandre Sunny Kovalenko wrote: On Wed, 2008-01-09 at 12:35 -0500, Joe Marcus Clarke wrote: On Wed, 2008-01-09 at 10:53 -0500, Alexandre Sunny Kovalenko wrote: I have seen recent commit WRT

Re: [patch] glib20, UTF-8 and string collation

2008-01-09 Thread Alexander Nedotsukov
Alexandre, The problem you exposed have its roots in Evo code. g_utf8_* stuff defined to work on *utf-8* strings only and have undefined behaviour on MBCS strings. It may sound stupid but crashes are allowed in this case :-) Even we apply your latest patch the true problem solution will be

Re: [patch] glib20, UTF-8 and string collation

2008-01-09 Thread Alexandre Sunny Kovalenko
On Thu, 2008-01-10 at 13:18 +0900, Alexander Nedotsukov wrote: Alexandre, The problem you exposed have its roots in Evo code. g_utf8_* stuff defined to work on *utf-8* strings only and have undefined behaviour on MBCS strings. It may sound stupid but crashes are allowed in this case :-)

Re: [patch] glib20, UTF-8 and string collation

2008-01-09 Thread Alexander Nedotsukov
Alexandre Sunny Kovalenko wrote: On Thu, 2008-01-10 at 13:18 +0900, Alexander Nedotsukov wrote: Alexandre, The problem you exposed have its roots in Evo code. g_utf8_* stuff defined to work on *utf-8* strings only and have undefined behaviour on MBCS strings. It may sound stupid but