#212 Issue closed: Error in grabbing name during saving partition layout (on name containing spaces)

Labels: bug, fixed / solved / done

gdha opened issue at 2013-03-24 11:48:

Error handling 'labels with spaces' in script layout/save/GNU/Linux/20_partition_layout.sh

++ read partition_nr size start junk
+++ grep '^3:' /tmp/rear.M5FFilyg9X8i2zw/tmp/parted
+++ cut -d : -f 6
++ type='EFI System Partition'
++ [[ -z EFI System Partition ]]
++ sed -i '/^3 /s/$/ EFI' System Partition/ /tmp/rear.M5FFilyg9X8i2zw/tmp/partitions
sed: -e expression #1, char 13: unterminated `s' command
++ read partition_nr size start junk
+++ grep '^4:' /tmp/rear.M5FFilyg9X8i2zw/tmp/parted
+++ cut -d : -f 6
++ type=freedom-boot
++ [[ -z freedom-boot ]]
++ sed -i '/^4 /s/$/ freedom-boot/' /tmp/rear.M5FFilyg9X8i2zw/tmp/partitions

gdha commented at 2013-03-24 14:07:

@jhoekx could you verify the fixes and confirm that I didn't forgot something?

jhoekx commented at 2013-03-24 14:19:

I have no test environment nearby. If you tested it, I believe it will work :-) I can't see any problems with it.

I prefer a commit title that is more descriptive than 'fixes issue #xxx' though. Something like 'Replace spaces in disk labels by 0x20'.

gdha commented at 2013-04-05 09:22:

restore test was fine. close this issue.

jsmeix commented at 2018-01-23 12:29:

Unfortunately via
the duplicated quoting to make parted work via
got removed (I assume because no comment explained why that overcomplicated
looking duplicated quoting is actually needed), cf.
and subsequent comments.

jsmeix commented at 2018-01-26 15:31:

With https://github.com/rear/rear/pull/1706 merged
this issue should be again fixed to a currently reasonable extent
which means: Currently it fails for UTF-8 encoded strings
so that UTF-8 encoded GPT partition names
are not (yet?) supported.

[Export of Github issue for rear/rear.]