diff options
author | Brian C. Lane <bcl@redhat.com> | 2020-11-20 13:26:31 -0800 |
---|---|---|
committer | Brian C. Lane <bcl@redhat.com> | 2020-11-20 14:00:58 -0800 |
commit | 945b13aed7e9762e00bda1b54e2c18eb3373a31d (patch) | |
tree | 86f3d915beec95dde1c332c0d0273ba2aef6adc9 | |
parent | 0d5f047b2855f3d39fa3afe6ec2a6129d18ddf33 (diff) | |
download | parted-945b13aed7e9762e00bda1b54e2c18eb3373a31d.tar.gz |
libparted: Remove disabled code
-rw-r--r-- | libparted/arch/gnu.c | 40 | ||||
-rw-r--r-- | libparted/labels/mac.c | 14 | ||||
-rw-r--r-- | libparted/labels/pc98.c | 5 |
3 files changed, 0 insertions, 59 deletions
diff --git a/libparted/arch/gnu.c b/libparted/arch/gnu.c index 321b70a..922b93d 100644 --- a/libparted/arch/gnu.c +++ b/libparted/arch/gnu.c @@ -359,46 +359,6 @@ gnu_close (PedDevice* dev) dev->dirty = 0; } -#if 0 - if (dev->dirty && dev->boot_dirty && dev->type != PED_DEVICE_FILE) { - /* ouch! */ - ped_exception_throw ( - PED_EXCEPTION_WARNING, - PED_EXCEPTION_OK, - _("The partition table cannot be re-read. This means " - "you need to reboot before mounting any " - "modified partitions. You also need to reinstall " - "your boot loader before you reboot (which may " - "require mounting modified partitions). It is " - "impossible do both things! So you'll need to " - "boot off a rescue disk, and reinstall your boot " - "loader from the rescue disk. Read section 4 of " - "the Parted User documentation for more " - "information.")); - return 1; - } - - if (dev->dirty && dev->type != PED_DEVICE_FILE) { - ped_exception_throw ( - PED_EXCEPTION_WARNING, - PED_EXCEPTION_IGNORE, - _("The partition table on %s cannot be re-read " - "(%s). This means the Hurd knows nothing about any " - "modifications you made. You should reboot your " - "computer before doing anything with %s."), - dev->path, strerror (errno), dev->path); - } - - if (dev->boot_dirty && dev->type != PED_DEVICE_FILE) { - ped_exception_throw ( - PED_EXCEPTION_WARNING, - PED_EXCEPTION_OK, - _("You should reinstall your boot loader before " - "rebooting. Read section 4 of the Parted User " - "documentation for more information.")); - } -#endif - return 1; } diff --git a/libparted/labels/mac.c b/libparted/labels/mac.c index 8980885..af9f4c3 100644 --- a/libparted/labels/mac.c +++ b/libparted/labels/mac.c @@ -560,20 +560,6 @@ _rawpart_analyse (MacRawPartition* raw_part, PedDisk* disk, int num) mac_part_data->data_region_length = PED_BE32_TO_CPU (raw_part->data_count); - /* boot region - we have no idea what this is for, but Mac OSX - * seems to put garbage here, and doesn't pay any attention to - * it afterwards. [clausen, dan burcaw] - */ -#if 0 - if (raw_part->boot_start) { - ped_exception_throw ( - PED_EXCEPTION_ERROR, - PED_EXCEPTION_CANCEL, - _("The boot region doesn't start at the start " - "of the partition.")); - goto error_destroy_part; - } -#endif mac_part_data->boot_region_length = PED_BE32_TO_CPU (raw_part->boot_count); diff --git a/libparted/labels/pc98.c b/libparted/labels/pc98.c index 328cd8d..b8993c4 100644 --- a/libparted/labels/pc98.c +++ b/libparted/labels/pc98.c @@ -418,13 +418,8 @@ fill_raw_part (PC98RawPartition* raw_part, const PedPartition* part) return 0; } raw_part->end_cyl = PED_CPU_TO_LE16(c); -#if 0 - raw_part->end_head = h; - raw_part->end_sector = s; -#else raw_part->end_head = 0; raw_part->end_sector = 0; -#endif return 1; } |