After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 623697 - GParted crashes moving partitions when size is multiple of 16 MiB
GParted crashes moving partitions when size is multiple of 16 MiB
Status: RESOLVED FIXED
Product: gparted
Classification: Other
Component: application
0.6.0
Other Linux
: Normal critical
: ---
Assigned To: gparted maintainers alias
gparted maintainers alias
Depends on:
Blocks:
 
 
Reported: 2010-07-06 17:12 UTC by Curtis Gedak
Modified: 2010-07-08 20:20 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
GParted 0.6.0 crash on 16MiB partition move (197.14 KB, image/png)
2010-07-06 18:43 UTC, Curtis Gedak
Details

Description Curtis Gedak 2010-07-06 17:12:56 UTC
GParted will crash if moving a primary partition to the end of the disk device.

This appears to happen only for partitions that are an exact multiple of 16 MiB in size.  Other partition sizes do not exhibit this behaviour and the operation runs to successful completion.

This crash was discovered using an MSDOS partition table, and the default alignment setting of "Align to MiB".
Comment 1 Curtis Gedak 2010-07-06 17:23:22 UTC
Further testing has revealed that the problem occurs when moving any partition that is an exact multiple of 16 MiB.

I will update the title accordingly.
Comment 2 Curtis Gedak 2010-07-06 18:43:18 UTC
Created attachment 165377 [details]
GParted 0.6.0 crash on 16MiB partition move

Attached is a screen shot of a GParted progress update immediately just before GParted crashed.

The screen shot was captured during a GDB debugging session and shows an action that should never occur.  Specifically "copy 0.00 B using a block size of 0.00 B".

This explains the following message shown in the debugger:
     Program received signal SIGFPE, Arithmetic exception.

The progress update shown in the screen shot occurred immediately after the "copy 16.0 MiB using a block size of 1.00 MiB".
Comment 3 Curtis Gedak 2010-07-06 19:03:15 UTC
Further investigation shows that this bug would also have existed in previous GParted versions, but would be based on a block size of 65536 sectors.  Versions prior to enhancing the optimal blocksize algorithm would have experienced the problem based on a block size of 32768 sectors.

The likelihood of encountering this problem in previous versions is lessened because the above multiples of sector sizes would be less likely to be encountered since the default alignment was then "Round to cylinders".
Comment 4 Curtis Gedak 2010-07-06 19:19:11 UTC
A fix for this bug has been committed to the GNOME git repository for inclusion
in the next release of GParted (0.6.1).

The relevant git commit can be viewed at the following link:
http://git.gnome.org/browse/gparted/commit/?id=e810b7f7f099a69a671be58ab7cd75475d55b57e
Comment 5 Curtis Gedak 2010-07-08 20:20:13 UTC
GParted 0.6.1, which includes this bug fix, was released on July 8, 2010.

Closing this bug.