GNU bug report logs - #15591
gpt mishandles non ascii partition names

Previous Next

Package: parted;

Reported by: Phillip Susi <psusi <at> ubuntu.com>

Date: Fri, 11 Oct 2013 19:00:02 UTC

Severity: normal

Merged with 15597

Done: Jim Meyering <jim <at> meyering.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Phillip Susi <psusi <at> ubuntu.com>
To: 15591 <at> debbugs.gnu.org
Subject: bug#15591: gpt mishandles non ascii partition names
Date: Fri, 11 Oct 2013 14:58:57 -0400
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Original bug report:
https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/1238446

The gpt partition table has 16 bit characters for the name, which I
assume are supposed to be UTF-16, but the bloody uefi standard is moot
on the subject.  Currently parted simply decimates the characters,
throwing out the upper 8 bits.  This corrupts characters that aren't
simple ascii, and at some later point, strlist.c calls mbstrtowcs(),
which chokes on the corrupt name causing parted to bail out with
"Error during translation".

I think that gpt.c needs to translate the UTF-16 to the native
multibyte encoding, but I have no idea how to do that.  The C standard
conversion functions all seem to use the current locale and don't have
a way to override it if you know this string is in UTF-16 ( and maybe
the current locale is UTF-8 ).

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJSWEpxAAoJEJrBOlT6nu75YYYH+gOqxQdKmRmPFfSAFbkOnXzf
9SqhaamWXNmqWLCaKHb4COO0S/Wg5Uu5Kzw0chqFbty0+S+Wa13/SM97S25SxUmh
q3sVnWbVwbOW5D2NAGhC7jjGwpZ9F4k45xE4DaHntSD1lsoYfq5+D25+4h7GTNqL
vliuuFhzUs5dQke/ONFnRfDb202ZC4j+HE7nBRwRm7VsUswsiiPVV8dz5iSQhkD1
/tx3N63A9aViBpFLlgGZu8XSaBHoE+4ZZ/COEGPzga372GDXyccODe0QfmErqWKI
3s0juqk5uOhUWvrWfzaYDtFEG+3AXuIXm8OT/SEQ4uKlqpCBKsFoBQLRGvoEPOE=
=0KW9
-----END PGP SIGNATURE-----




This bug report was last modified 11 years and 154 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.