Gparted should return "1 Cancel" when its operation fails
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gparted (Ubuntu) |
Fix Released
|
Medium
|
Colin Watson |
Bug Description
Gparted should return "1 Cancel" from the "apply" command when one of its operations fails.
Specifically, I have tried to resize an NTFS partition through ubiquity (which embeds gparted for manual partitioning), and when this operation fails, gparted does not emit a cancel/error code.
Full description (pasted from bug 45543) below:
-----------
Ok I'll try and explain exactly what I'm seeing. I think it boils down to this: if my NTFS partition is not "clean", the resize fails but the installer continues. If I run checkdisk from inside Windows, and then run the installer, the whole procedure works flawlessly. But I (and I'm sure others as well) frequently seem to have NTFS partitions that are not unmounted cleanly for whatever reason. In this case I think the installer should probably halt.
So here's what I did:
1) I choose manual partitioning, and it shows me the partition layout of my disk. I've attached resize-results.zip, which contains file "fdisk.original" which is the output of fdisk -l /dev/hda, which you can examine to see the makeup yourself -- a big hda1, a 3.5Gb hda2, then lots of freespace.
2) I right-click hda2 and choose resize. I shrink it to 1.5Gb using the slider. Then I select the freespace, choose "new" and create an ext3 partition that will become my root partition.
3) After I click "Next", it warns me that it's about to resize, I say OK, and it shows a dialog and goes through steps 1 and 2: resizing hda2 and then creating the new hda3 for root.
4) When the mount points screen appears, it still shows that hda2 is 3.5Gb. The resize of NTFS failed, but the installer continued to the next screen as if it had succeeded. I think at this point it should have halted and told me to go run checkdisk in Windows (or something), right? In resize-results.zip there is also a file "fdisk.
The resize-results.zip also contains the installer log, which contains line "gparted replied: - FORMAT /dev/hda4 ext3" even though the previous resize operation failed. I don't see a line stating that the resize failed, btw. But it did. :-)
zip file containing fdisk output before and after resize operation, and ubiquity installer log.