[Parted-maintainers] Bug#463720: [bug-fdisk] Debian bug 463720 - segfault using /dev/sda [SOLUTION]
Arthur Marsh
arthur.marsh at internode.on.net
Sun Dec 28 17:44:22 UTC 2008
Thanks, the patch worked:
ls -al `which fdisk`
-rwxr-xr-x 1 root root 84640 2008-12-29 04:08 /sbin/fdisk
victoria:/usr/src/sound# fdisk -l /dev/sda
GNU Fdisk 1.1
Copyright (C) 1998 - 2006 Free Software Foundation, Inc.
This program is free software, covered by the GNU General Public License.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
Disk /dev/sda: 4 GB, 4334722560 bytes
255 heads, 63 sectors/track, 527 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 261 2096451 6 FAT16
/dev/sda2 262 527 2128612 f Extended LBA
/dev/sda5 262 527 2128612 b FAT32
Warning: Partition 5 does not end on cylinder boundary.
Christian wrote, on 2008-12-29 00:47:
>
>> ~/# ./fdisk -l /dev/hda
>> GNU Fdisk 1.1
>> Copyright (C) 1998 - 2006 Free Software Foundation, Inc.
>> This program is free software, covered by the GNU General Public
>> License.
>>
>> This program is distributed in the hope that it will be useful,
>> but WITHOUT ANY WARRANTY; without even the implied warranty of
>> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
>> GNU General Public License for more details.
>>
>> Floating point exception
>>
>> I will examine it tomorrow and try to fix the bug.
>>
>> Thank's for report!!! :)
>>
>> Christian.
>>
>>
>>
>>
>> _______________________________________________
>> Bug-fdisk mailing list
>> Bug-fdisk at gnu.org
>> http://lists.gnu.org/mailman/listinfo/bug-fdisk
>>
> Stupid bug! :)
>
> Solution is very simple: change "src/ui.c" line 720:
>
> fdisk_do_list_devices(&disk);
>
> removing the `&' operator:
>
> fdisk_do_list_devices(disk);
>
> After recompiling GNU fdisk we have:
>
> ~/# ./fdisk -l /dev/hda
> GNU Fdisk 1.1
> Copyright (C) 1998 - 2006 Free Software Foundation, Inc.
> This program is free software, covered by the GNU General Public
> License.
>
> This program is distributed in the hope that it will be useful,
> but WITHOUT ANY WARRANTY; without even the implied warranty of
> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> GNU General Public License for more details.
>
>
> Disk /dev/hda: 30 GB, 30014046720 bytes
> 255 heads, 63 sectors/track, 3649 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
> Device Boot Start End Blocks Id System
> /dev/hda1 * 1 1825 14659281 c Linux
> /dev/hda2 1826 2434 4883760 83 Linux
> /dev/hda3 2435 2497 498015 82 Linux swap
> /dev/hda4 2498 3649 9245407 83 Linux
> ~/#
>
> Happy partition lists! ;)
>
> Christian.
>
>
>
> _______________________________________________
> Bug-fdisk mailing list
> Bug-fdisk at gnu.org
> http://lists.gnu.org/mailman/listinfo/bug-fdisk
>
More information about the Parted-maintainers
mailing list