gparted does not shrink partitions
Bug #22772 reported by
David Meier
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gparted (Ubuntu) |
Fix Released
|
Medium
|
Daniel Holbach |
Bug Description
Shrinking partitions in gparted fails. I tried ext2/3 and reiserfs. In terminal,
I get the following errors:
It seems the size value is given including a point, like "2.508M" instead of
"2508M".
with reiser: resizer_reiserfs: the new size value is wrong.
with ext: resize2fs: ungültige Dateisystemgröße - 2.508M
(invalid filesystem size)
Calling resize2fs manually without a point works, with a point it fails with the
above error message.
I also tried shrinking an NTFS partition, which only worked with a new size <1000M.
To post a comment you must log in.
The error seems to bei in Utils.h:
inline Glib::ustring num_to_str( Sector number )
{
std::ostringstream os;
os .imbue( std::locale("") );
os << number ;
return os .str() ;
}
this is used by the GUI as well as by the actual resize-function, where the
formatting makes no sense. Commenting out that line
// os .imbue( std::locale("") );
makes the partition list in the GUI look a bit less pretty, but at least
shrinking works then.
This is not relevant for growing, as no size parameter is handed then at all to
the filesystem resizer.