Re: [PATCH] ISO9660 I18N Joliet label support



On Wed, 2005-01-12 at 12:41 +1300, leon breedt wrote:
> On Tue, 11 Jan 2005 11:08:56 +0100, Alexander Larsson <alexl redhat com> wrote:
> > Looks good to me (although i don't know squat about joliet), applied.
> Hi Alex,
> 
> Following some further discussion, the Gentoo guys found usability
> issue with the way the label is selected in HAL (the same method is
> used in the previous patch).
> 
> If the ISO and Joliet volume labels have the same leading 16
> characters, the ISO label should be used, as the Joliet label is
> limited to 16 characters due to being UTF-16 encoded, while the ISO
> label is up to 32 characters ASCII. If a strncmp of the first 16
> characters (after the UTF16 => UTF-8 conversion) succeeds, it means
> that the Joliet label contains a truncated version of the ISO label.
> 
> The attached patch also removes an incorrect NUL byte check on the
> UTF-16 label.
> 
> Incorrect since UTF-16 can contain embedded NULs, and we should rely
> on g_convert to determine whether its valid or not.
> 
> I've attached a tested patch that should resolve these two issues.

Applied. Thanks.

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Alexander Larsson                                            Red Hat, Inc 
                   alexl redhat com    alla lysator liu se 
He's an uncontrollable Catholic cowboy possessed of the uncanny powers of an 
insect. She's a warm-hearted belly-dancing socialite from the wrong side of 
the tracks. They fight crime! 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]