[Parted-maintainers] Bug#279732: marked as done (parted doesn't print large partitions correctly [PATCH])
Debian Bug Tracking System
owner@bugs.debian.org
Fri, 26 Nov 2004 08:33:08 -0800
Your message dated Fri, 26 Nov 2004 11:17:06 -0500
with message-id <E1CXimQ-0003Zk-00@newraff.debian.org>
and subject line Bug#279732: fixed in parted 1.6.11-9
has caused the attached Bug report to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere. Please contact me immediately.)
Debian bug tracking system administrator
(administrator, Debian Bugs database)
--------------------------------------
Received: (at submit) by bugs.debian.org; 4 Nov 2004 22:45:06 +0000
>From peterc@gelato.unsw.edu.au Thu Nov 04 14:45:06 2004
Return-path: <peterc@gelato.unsw.edu.au>
Received: from note.orchestra.cse.unsw.edu.au [129.94.242.24] (root)
by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
id 1CPqLp-0000QX-00; Thu, 04 Nov 2004 14:45:06 -0800
Received: From lemon.gelato.unsw.edu.au ([129.94.173.27])
(for <submit@bugs.debian.org>) By note With Smtp ;
Fri, 5 Nov 2004 09:45:02 +1100
Received: from berry.gelato.unsw.edu.au ([129.94.173.230]:40791)
by lemon.gelato.unsw.edu.au with esmtp (Exim 4.30)
id 1CPqLj-0007XL-Tb
for submit@bugs.debian.org; Fri, 05 Nov 2004 09:44:59 +1100
Received: from peterc by berry.gelato.unsw.EDU.AU with local (Exim 3.36 #1 (Debian))
id 1CPqLj-0006bY-00
for <submit@bugs.debian.org>; Fri, 05 Nov 2004 09:44:59 +1100
From: Peter Chubb <peterc@gelato.unsw.edu.au>
Sender: Peter Chubb <peterc@berry>
To: submit@bugs.debian.org
Date: Fri, 5 Nov 2004 09:44:59 +1100
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-ID: <16778.45291.459404.514037@berry.gelato.unsw.EDU.AU>
Subject: parted doesn't print large partitions correctly [PATCH]
X-Mailer: VM 7.17 under 21.4 (patch 15) "Security Through Obscurity" XEmacs Lucid
Comments: Hyperbole mail buttons accepted, v04.18.
X-Face: GgFg(Z>fx((4\32hvXq<)|jndSniCH~~$D)Ka:P@e@JR1P%Vr}EwUdfwf-4j\rUs#JR{'h#
!]])6%Jh~b$VA|ALhnpPiHu[-x~@<"@Iv&|%R)Fq[[,(&Z'O)Q)xCqe1\M[F8#9l8~}#u$S$Rm`S9%
\'T@`:&8>Sb*c5d'=eDYI&GF`+t[LfDH="MP5rwOO]w>ALi7'=QJHz&y&C&TE_3j!
Delivered-To: submit@bugs.debian.org
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2004_03_25
(1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-8.0 required=4.0 tests=BAYES_00,HAS_PACKAGE
autolearn=no version=2.60-bugs.debian.org_2004_03_25
X-Spam-Level:
Package: parted
Version: 1.6.11-7
If you have partitions bigger than 1TB, parted prints them
incorrectly, because it casts the partition size (in sectors) to int,
which is only 32-bits.
Here is a patch. I also fixed up some rather strange casting.
Index: parted-1.6.11/parted/parted.c
===================================================================
--- parted-1.6.11.orig/parted/parted.c 2003-06-30 11:44:14.000000000 +1000
+++ parted-1.6.11/parted/parted.c 2004-11-05 09:41:28.153948819 +1100
@@ -810,8 +810,8 @@
printf (_("Flags: ")); partition_print_flags (part); printf("\n");
printf (_("File System: %s\n"), fs->type->name);
printf (_("Size: %10.3fMb (%d%%)\n"),
- part->geom.length * 1.0 / MEGABYTE_SECTORS,
- (int) 100 * part->geom.length / part->disk->dev->length);
+ ((double)part->geom.length) / MEGABYTE_SECTORS,
+ (int)(100.0 * part->geom.length / part->disk->dev->length));
resize_constraint = ped_file_system_get_resize_constraint (fs);
if (resize_constraint) {
@@ -889,8 +889,8 @@
printf ("%-5d ", part->num);
printf ("%10.3f %10.3f ",
- (int) part->geom.start * 1.0 / MEGABYTE_SECTORS,
- (int) part->geom.end * 1.0 / MEGABYTE_SECTORS);
+ (double)part->geom.start / MEGABYTE_SECTORS,
+ (double)part->geom.end / MEGABYTE_SECTORS);
if (has_extended)
printf ("%-9s ",
@@ -967,8 +967,8 @@
"Do you want to add it to the partition table?"),
fs_type->name,
ped_partition_type_get_name (part->type),
- (int) probed->start * 1.0 / MEGABYTE_SECTORS,
- (int) probed->end * 1.0 / MEGABYTE_SECTORS);
+ (double)probed->start / MEGABYTE_SECTORS,
+ (double)probed->end / MEGABYTE_SECTORS);
switch (ex_opt) {
case PED_EXCEPTION_CANCEL: return -1;
---------------------------------------
Received: (at 279732-close) by bugs.debian.org; 26 Nov 2004 16:23:02 +0000
>From katie@ftp-master.debian.org Fri Nov 26 08:23:02 2004
Return-path: <katie@ftp-master.debian.org>
Received: from newraff.debian.org [208.185.25.31] (mail)
by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
id 1CXisA-0003yw-00; Fri, 26 Nov 2004 08:23:02 -0800
Received: from katie by newraff.debian.org with local (Exim 3.35 1 (Debian))
id 1CXimQ-0003Zk-00; Fri, 26 Nov 2004 11:17:06 -0500
From: Sven Luther <luther@debian.org>
To: 279732-close@bugs.debian.org
X-Katie: $Revision: 1.51 $
Subject: Bug#279732: fixed in parted 1.6.11-9
Message-Id: <E1CXimQ-0003Zk-00@newraff.debian.org>
Sender: Archive Administrator <katie@ftp-master.debian.org>
Date: Fri, 26 Nov 2004 11:17:06 -0500
Delivered-To: 279732-close@bugs.debian.org
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2004_03_25
(1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-6.0 required=4.0 tests=BAYES_00,HAS_BUG_NUMBER
autolearn=no version=2.60-bugs.debian.org_2004_03_25
X-Spam-Level:
Source: parted
Source-Version: 1.6.11-9
We believe that the bug you reported is fixed in the latest version of
parted, which is due to be installed in the Debian FTP archive:
libparted1.6-0_1.6.11-9_powerpc.deb
to pool/main/p/parted/libparted1.6-0_1.6.11-9_powerpc.deb
libparted1.6-dbg_1.6.11-9_powerpc.deb
to pool/main/p/parted/libparted1.6-dbg_1.6.11-9_powerpc.deb
libparted1.6-dev_1.6.11-9_powerpc.deb
to pool/main/p/parted/libparted1.6-dev_1.6.11-9_powerpc.deb
libparted1.6-i18n_1.6.11-9_all.deb
to pool/main/p/parted/libparted1.6-i18n_1.6.11-9_all.deb
libparted1.6-udeb_1.6.11-9_powerpc.udeb
to pool/main/p/parted/libparted1.6-udeb_1.6.11-9_powerpc.udeb
parted-doc_1.6.11-9_all.deb
to pool/main/p/parted/parted-doc_1.6.11-9_all.deb
parted-udeb_1.6.11-9_powerpc.udeb
to pool/main/p/parted/parted-udeb_1.6.11-9_powerpc.udeb
parted_1.6.11-9.diff.gz
to pool/main/p/parted/parted_1.6.11-9.diff.gz
parted_1.6.11-9.dsc
to pool/main/p/parted/parted_1.6.11-9.dsc
parted_1.6.11-9_powerpc.deb
to pool/main/p/parted/parted_1.6.11-9_powerpc.deb
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to 279732@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Sven Luther <luther@debian.org> (supplier of updated parted package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Format: 1.7
Date: Thu, 25 Nov 2004 14:32:36 +0100
Source: parted
Binary: parted-udeb parted-doc libparted1.6-0 libparted1.6-dev libparted1.6-udeb parted libparted1.6-i18n libparted1.6-dbg
Architecture: source powerpc all
Version: 1.6.11-9
Distribution: unstable
Urgency: low
Maintainer: Parted Maintainer Team <parted-maintainers@lists.alioth.debian.org>
Changed-By: Sven Luther <luther@debian.org>
Description:
libparted1.6-0 - The GNU Parted disk partitioning shared library
libparted1.6-dbg - The GNU Parted disk partitioning library debug development files
libparted1.6-dev - The GNU Parted disk partitioning library development files
libparted1.6-i18n - The GNU Parted disk partitioning library i18n support
libparted1.6-udeb - The GNU Parted disk partitioning shared library (udeb)
parted - The GNU Parted disk partition resizing program
parted-doc - The GNU Parted disk partition resizing program documentation
parted-udeb - The GNU Parted disk partition resizing program (udeb)
Closes: 279732
Changes:
parted (1.6.11-9) unstable; urgency=low
.
* Applied large-partitions patch to show correct partition data. Thanks
go to Peter Chubb <peterc@gelato.unsw.edu.au> for providing the patch.
(Closes: #279732)
Files:
8b0321acc411d0ea70a31b28287ad5f8 926 admin optional parted_1.6.11-9.dsc
558ac03211ff3b02169f6b4c46550cff 91899 admin optional parted_1.6.11-9.diff.gz
02bf16ca2cb199d698998c907ba61b82 73268 admin optional parted_1.6.11-9_powerpc.deb
49b81c6a69a48cf0926b714a99ba2a99 23264 debian-installer extra parted-udeb_1.6.11-9_powerpc.udeb
c45b07f0e5791fbf7c062bfc625c1fc9 206408 libs optional libparted1.6-0_1.6.11-9_powerpc.deb
8386cbe2d3953472503847b8d0e8b224 155254 debian-installer extra libparted1.6-udeb_1.6.11-9_powerpc.udeb
3ff262c1405419099660d9129e205860 268192 libdevel optional libparted1.6-dev_1.6.11-9_powerpc.deb
1dd1cc6960f5c37bc124451a344e7c71 1229332 libdevel extra libparted1.6-dbg_1.6.11-9_powerpc.deb
7126c05c66ecb6ae457eaffe3128fc44 285898 libs optional libparted1.6-i18n_1.6.11-9_all.deb
64ab85c974409a4f2fd838d9cbd6649d 129128 doc optional parted-doc_1.6.11-9_all.deb
package-type: udeb
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)
iD8DBQFBp1Mw2WTeT3CRQaQRAgEOAKCnug5ftPjcigRR/MJi2yHxBLejvQCgh302
kLnTIG4vjhdhJHRu4KytNEs=
=oyLZ
-----END PGP SIGNATURE-----