Subject: bug#15591: [PATCH] libparted: handle i18n gpt partition names correctly

From: Phillip Susi <[email-masked]>
Date: Fri, 20 Dec 2013 09:16:08 -0500

On 12/20/2013 12:35 AM, Jim Meyering wrote:
> Ideally, the script would create a partition table from scratch
> and then create a partition table with a unicode name, then verify
> that it can be read/displayed properly.  Then there's no issue
> with storing an image in git.
> 
> If you don't have the time or inclination, point me to an
> offending image and I'll derive a stand-alone test that doesn't
> need that image.

You can create one with parted after applying the patch, or with
gdisk, and entering a unicode character in the name.  Also git has no
problem with binary files; util-linux includes several bzip2'd binary
disk images for its test suite.

Note that trying to use unicode characters with parted without this
patch appears to work, since writing the string spreads it out over
multiple bytes with zeros between, and reading it back undoes this
damage.  Setting the name with gdisk causes parted to puke when it
reads it.