Bruno Haible wrote:
> 
> Find attached the fix that I just committed. Thanks for the report.
> 
> 2008-08-03  Bruno Haible  <[EMAIL PROTECTED]>
> 
>       * x-python.c (mixed_string_buffer_append): Replace a lone high
>       surrogate with U+FFFD.
>       Reported by Yann <[EMAIL PROTECTED]>
>       via Santiago Vila <[EMAIL PROTECTED]>.
> 
> *** x-python.c        20 Apr 2008 05:23:52 -0000      1.32
> --- x-python.c        3 Aug 2008 19:56:58 -0000
> ***************
> *** 930,935 ****
> --- 930,940 ----
>   
>         if (c >= UNICODE (0xd800) && c < UNICODE (0xdc00))
>           bp->utf16_surr = UNICODE_VALUE (c);
> +       else if (c >= UNICODE (0xdc00) && c < UNICODE (0xe000))
> +         {
> +           /* A half surrogate is invalid, therefore use U+FFFD instead.  */
> +           mixed_string_buffer_append_unicode (bp, 0xfffd);
> +         }
>         else
>           mixed_string_buffer_append_unicode (bp, UNICODE_VALUE (c));
>       }
> 

Could this patch be included in a new debian package please?

-- 
Yann



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to