[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly
From: |
Jim Meyering |
Subject: |
bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly |
Date: |
Thu, 19 Dec 2013 14:13:45 -0800 |
On Thu, Dec 19, 2013 at 1:25 PM, Phillip Susi <address@hidden> wrote:
> gpt.c was simply truncating the UTF-16 characters stored
> in the partition name field to 8 bits. This corrupted non
> ascii characters which later resulted in parted crashing in
> strlist.c trying to convert the now invalid multi byte
> characters to wchar.
>
> gpt.c will now properly convert the UTF-16 to the current
> locale encoding.
Hi Philip,
Thanks for fixing that. Your patch looks good.
One nit:
> + gpt_part_data->translated_name = strdup(name);
Would you please adjust that to handle strdup failure?
Perhaps just by using xstrdup in place of strdup.
Also, it'd be great to add a test case that fails without this fix?
Thanks,
Jim
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Phillip Susi, 2013/12/19
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly,
Jim Meyering <=
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Jim Meyering, 2013/12/19
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Phillip Susi, 2013/12/19
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Jim Meyering, 2013/12/20
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Phillip Susi, 2013/12/20
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Jim Meyering, 2013/12/20
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Phillip Susi, 2013/12/20
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Jim Meyering, 2013/12/21
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Phillip Susi, 2013/12/20
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Jim Meyering, 2013/12/21
- bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly, Phillip Susi, 2013/12/21