diff --git a/.gitignore b/.gitignore index 85e6502..d287cc2 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,5 @@ clog /parted-3.0.tar.xz.sig /parted-3.1.tar.xz /parted-3.1.tar.xz.sig +/parted-3.1.90.tar.xz +/parted-3.1.90.tar.xz.sig diff --git a/0001-maint-post-release-administrivia.patch b/0001-maint-post-release-administrivia.patch deleted file mode 100644 index 9dd3336..0000000 --- a/0001-maint-post-release-administrivia.patch +++ /dev/null @@ -1,50 +0,0 @@ -From f6835518a7a8722b247079799a9145c3101f9a8a Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Fri, 2 Mar 2012 17:59:32 +0100 -Subject: [PATCH 001/131] maint: post-release administrivia - -* NEWS: Add header line for next release. -* .prev-version: Record previous version. -* cfg.mk (old_NEWS_hash): Auto-update. ---- - .prev-version | 2 +- - NEWS | 3 +++ - cfg.mk | 2 +- - 3 files changed, 5 insertions(+), 2 deletions(-) - -diff --git a/.prev-version b/.prev-version -index 9f55b2c..8c50098 100644 ---- a/.prev-version -+++ b/.prev-version -@@ -1 +1 @@ --3.0 -+3.1 -diff --git a/NEWS b/NEWS -index fe0fcdd..3bef20e 100644 ---- a/NEWS -+++ b/NEWS -@@ -1,5 +1,8 @@ - GNU parted NEWS -*- outline -*- - -+* Noteworthy changes in release ?.? (????-??-??) [?] -+ -+ - * Noteworthy changes in release 3.1 (2012-03-02) [stable] - - ** New features -diff --git a/cfg.mk b/cfg.mk -index ba8ba77..c6a00c8 100644 ---- a/cfg.mk -+++ b/cfg.mk -@@ -42,7 +42,7 @@ local-checks-to-skip = \ - # Now that we have better (check.mk) tests, make this the default. - export VERBOSE = yes - --old_NEWS_hash = 04810d10a532cf2e75d602ddda0d64b1 -+old_NEWS_hash = bd453bcf049e292a9677c094d24a29dd - - include $(srcdir)/dist-check.mk - --- -1.9.3 - diff --git a/0002-libparted-check-PMBR-before-GPT-partition-table.patch b/0002-libparted-check-PMBR-before-GPT-partition-table.patch deleted file mode 100644 index 99d61cd..0000000 --- a/0002-libparted-check-PMBR-before-GPT-partition-table.patch +++ /dev/null @@ -1,100 +0,0 @@ -From b55724f291fa405f652fbbc5cae6e36cc8a2d200 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 20 Mar 2012 17:25:22 -0700 -Subject: [PATCH 002/131] libparted: check PMBR before GPT partition table - -The UEFI spec requires that a valid GPT disk label have a PMBR -partition. This moves the PMBR check to before the GPT check, -exiting gpt_probe with a 0 if the PMBR is not valid. - -The previous behavior would cause problems in the following situation: - 1. format a disk as GPT - 2. re-format it as MSDOS using tools that don't understand GPT - -Subsequent operations with parted would then complain about the invalid -PMBR, but would not allow the disk to be used as an msdos disk. This -change causes parted to recognize the msdos partition table. - -* libparted/labels/gpt.c (gpt_probe): Move _pmbr_is_valid test. -Reported by Chris Murphy in http://bugzilla.redhat.com/805272 ---- - libparted/labels/gpt.c | 47 ++++++++++++++--------------------------------- - 1 file changed, 14 insertions(+), 33 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 84bdc12..91ad71a 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -457,7 +457,6 @@ _pmbr_is_valid (const LegacyMBR_t *mbr) - static int - gpt_probe (const PedDevice *dev) - { -- GuidPartitionTableHeader_t *gpt = NULL; - int gpt_sig_found = 0; - - PED_ASSERT (dev != NULL); -@@ -465,47 +464,29 @@ gpt_probe (const PedDevice *dev) - if (dev->length <= 1) - return 0; - -+ void *label; -+ if (!ptt_read_sector (dev, 0, &label)) -+ return 0; -+ -+ if (!_pmbr_is_valid (label)) -+ { -+ free (label); -+ return 0; -+ } -+ free (label); -+ - void *pth_raw = ped_malloc (pth_get_size (dev)); - if (ped_device_read (dev, pth_raw, 1, GPT_HEADER_SECTORS) - || ped_device_read (dev, pth_raw, dev->length - 1, GPT_HEADER_SECTORS)) - { -- gpt = pth_new_from_raw (dev, pth_raw); -+ GuidPartitionTableHeader_t *gpt = pth_new_from_raw (dev, pth_raw); - if (gpt->Signature == PED_CPU_TO_LE64 (GPT_HEADER_SIGNATURE)) - gpt_sig_found = 1; -+ pth_free (gpt); - } -- - free (pth_raw); - -- pth_free (gpt); -- -- if (!gpt_sig_found) -- return 0; -- -- void *label; -- if (!ptt_read_sector (dev, 0, &label)) -- return 0; -- -- int ok = 1; -- if (!_pmbr_is_valid ((const LegacyMBR_t *) label)) -- { -- int ex_status = ped_exception_throw -- (PED_EXCEPTION_WARNING, -- PED_EXCEPTION_YES_NO, -- _("%s contains GPT signatures, indicating that it has " -- "a GPT table. However, it does not have a valid " -- "fake msdos partition table, as it should. Perhaps " -- "it was corrupted -- possibly by a program that " -- "doesn't understand GPT partition tables. Or " -- "perhaps you deleted the GPT table, and are now " -- "using an msdos partition table. Is this a GPT " -- "partition table?"), -- dev->path); -- if (ex_status == PED_EXCEPTION_NO) -- ok = 0; -- } -- -- free (label); -- return ok; -+ return gpt_sig_found; - } - - static PedDisk * --- -1.9.3 - diff --git a/0003-tests-add-t0301-overwrite-gpt-pmbr.sh.patch b/0003-tests-add-t0301-overwrite-gpt-pmbr.sh.patch deleted file mode 100644 index c7711b0..0000000 --- a/0003-tests-add-t0301-overwrite-gpt-pmbr.sh.patch +++ /dev/null @@ -1,98 +0,0 @@ -From 5021bbdc6ee892890c2c6fede806b9ad6a6a9378 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 20 Mar 2012 17:25:23 -0700 -Subject: [PATCH 003/131] tests: add t0301-overwrite-gpt-pmbr.sh - -Make sure parted checks the PMBR before the GPT partition table. - -* NEWS: Update with new GPT behavior. -* tests/overwrite-gpt-pmbr.sh: New test. -* tests/Makefile.am (TESTS): Add it. ---- - NEWS | 5 +++++ - tests/Makefile.am | 1 + - tests/t0301-overwrite-gpt-pmbr.sh | 44 +++++++++++++++++++++++++++++++++++++++ - 3 files changed, 50 insertions(+) - create mode 100755 tests/t0301-overwrite-gpt-pmbr.sh - -diff --git a/NEWS b/NEWS -index 3bef20e..3969c44 100644 ---- a/NEWS -+++ b/NEWS -@@ -2,6 +2,11 @@ GNU parted NEWS -*- outline -*- - - * Noteworthy changes in release ?.? (????-??-??) [?] - -+** Bug Fixes -+ -+ libparted: treat a disk with no pMBR as an msdos-labeled disk -+ even when it has valid GPT headers. -+ - - * Noteworthy changes in release 3.1 (2012-03-02) [stable] - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 1b37fd9..1264812 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -28,6 +28,7 @@ TESTS = \ - t0250-gpt.sh \ - t0280-gpt-corrupt.sh \ - t0300-dos-on-gpt.sh \ -+ t0301-overwrite-gpt-pmbr.sh \ - t0400-loop-clobber-infloop.sh \ - t0500-dup-clobber.sh \ - t0501-duplicate.sh \ -diff --git a/tests/t0301-overwrite-gpt-pmbr.sh b/tests/t0301-overwrite-gpt-pmbr.sh -new file mode 100755 -index 0000000..e7edb66 ---- /dev/null -+++ b/tests/t0301-overwrite-gpt-pmbr.sh -@@ -0,0 +1,44 @@ -+#!/bin/sh -+# Test creating a msdos partition over a GPT partition with -+# fdisk which doesn't remove the GPT partitions, only the PMBR -+ -+# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+ -+ss=$sector_size_ -+dev=loop-file -+ -+# Create a GPT partition table. -+dd if=/dev/null of=$dev bs=$ss seek=80 2> /dev/null || framework_failure -+parted -s $dev mklabel gpt > out 2>&1 || framework_failure_ -+compare /dev/null out || framework_failure_ -+ -+# Create an MSDOS partition table in another file. -+dd if=/dev/null of=m bs=$ss seek=80 2> /dev/null || framework_failure -+parted -s m mklabel msdos > out 2>&1 || framework_failure_ -+compare /dev/null out || framework_failure_ -+ -+# Transplant the MSDOS MBR into the GPT-formatted image. -+dd if=m of=$dev bs=$ss count=1 conv=notrunc || framework_failure_ -+ -+# Now, try to create a GPT partition table in $dev. -+# Before, parted would prompt, asking about the apparent inconsistency. -+parted -s $dev mklabel gpt > out 2>&1 || fail=1 -+# expect no output -+compare /dev/null out || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0004-tests-remove-bogus-envvar-setting-from-t0300-dos-on-.patch b/0004-tests-remove-bogus-envvar-setting-from-t0300-dos-on-.patch deleted file mode 100644 index cbe82ee..0000000 --- a/0004-tests-remove-bogus-envvar-setting-from-t0300-dos-on-.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 7fd33a6d24da6a82b830552999b2332140f556d4 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Mon, 26 Mar 2012 21:52:08 +0200 -Subject: [PATCH 004/131] tests: remove bogus envvar setting from - t0300-dos-on-gpt.sh - -* tests/t0300-dos-on-gpt.sh: Remove envvar setting that effectively -disabled testing(only in this test) of simulated sector sizes smaller -than 4KiB. -Also, use a much smaller backing file. ---- - tests/t0300-dos-on-gpt.sh | 6 ++---- - 1 file changed, 2 insertions(+), 4 deletions(-) - -diff --git a/tests/t0300-dos-on-gpt.sh b/tests/t0300-dos-on-gpt.sh -index 41bc391..fbe8d7c 100755 ---- a/tests/t0300-dos-on-gpt.sh -+++ b/tests/t0300-dos-on-gpt.sh -@@ -17,13 +17,11 @@ - # along with this program. If not, see . - - . "${srcdir=.}/init.sh"; path_prepend_ ../parted -- --PARTED_SECTOR_SIZE=4096 --export PARTED_SECTOR_SIZE -+ss=$sector_size_ - - dev=loop-file - # create a backing file large enough for a GPT partition table --dd if=/dev/null of=$dev seek=4001 2> /dev/null || framework_failure -+dd if=/dev/null of=$dev bs=$ss seek=80 2> /dev/null || framework_failure - - # create a GPT partition table - parted -s $dev mklabel gpt > out 2>&1 || fail=1 --- -1.9.3 - diff --git a/0005-gpt-fix-endianness-bug-in-gpt_get_max_supported_part.patch b/0005-gpt-fix-endianness-bug-in-gpt_get_max_supported_part.patch deleted file mode 100644 index f9778d6..0000000 --- a/0005-gpt-fix-endianness-bug-in-gpt_get_max_supported_part.patch +++ /dev/null @@ -1,51 +0,0 @@ -From 4ac1c02b590668c93afdb48900e0858de58cda3a Mon Sep 17 00:00:00 2001 -From: "Richard W.M. Jones" -Date: Fri, 8 Jun 2012 13:19:25 +0100 -Subject: [PATCH 005/131] gpt: fix endianness bug in - gpt_get_max_supported_partition_count - -* libparted/labels/gpt.c (gpt_get_max_supported_partition_count): -Take endianness of pth->FirstUsableLBA into account (64-bit, -little endian) when calculating the maximum number of partitions. -* NEWS (Bug fixes): Mention it. ---- - NEWS | 3 +++ - libparted/labels/gpt.c | 4 ++-- - 2 files changed, 5 insertions(+), 2 deletions(-) - -diff --git a/NEWS b/NEWS -index 3969c44..f929b99 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: gpt: fix gpt_get_max_supported_partition_count to work -+ also on little-endian systems. -+ - libparted: treat a disk with no pMBR as an msdos-labeled disk - even when it has valid GPT headers. - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 91ad71a..6032e3f 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -1785,12 +1785,12 @@ gpt_get_max_supported_partition_count (const PedDisk *disk, int *max_n) - - if (!_header_is_valid (disk, pth, 1)) - { -- pth->FirstUsableLBA = 34; -+ pth->FirstUsableLBA = PED_CPU_TO_LE64 (34); - pth->SizeOfPartitionEntry - = PED_CPU_TO_LE32 (sizeof (GuidPartitionEntry_t)); - } - -- *max_n = (disk->dev->sector_size * (pth->FirstUsableLBA - 2) -+ *max_n = (disk->dev->sector_size * (PED_LE64_TO_CPU (pth->FirstUsableLBA) - 2) - / PED_LE32_TO_CPU (pth->SizeOfPartitionEntry)); - pth_free (pth); - return true; --- -1.9.3 - diff --git a/0006-tests-add-a-test-to-exercise-just-fixed-code.patch b/0006-tests-add-a-test-to-exercise-just-fixed-code.patch deleted file mode 100644 index 15297d8..0000000 --- a/0006-tests-add-a-test-to-exercise-just-fixed-code.patch +++ /dev/null @@ -1,110 +0,0 @@ -From e38df2d81f0a4647711ffeb92a32c99e7ce9a92d Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sat, 9 Jun 2012 17:26:21 +0200 -Subject: [PATCH 006/131] tests: add a test to exercise just-fixed code - -* tests/print-max.c: Extend to provide coverage of -ped_disk_get_max_supported_partition_count, too. -* tests/t9021-maxima.sh (max_n_partitions): New function, with -naively hard-coded max-number-of-partitions-per-partition-table-type -values. -Use it to ensure that each expected value matches the actual one. -* cfg.mk: Exempt this test's use of error from the syntax-check -for unmarked diagnostics. ---- - cfg.mk | 2 ++ - tests/print-max.c | 10 ++++++++++ - tests/t9021-maxima.sh | 26 +++++++++++++++++++++++++- - 3 files changed, 37 insertions(+), 1 deletion(-) - -diff --git a/cfg.mk b/cfg.mk -index c6a00c8..45d2ac2 100644 ---- a/cfg.mk -+++ b/cfg.mk -@@ -69,3 +69,5 @@ exclude_file_name_regexp--sc_prohibit_always-defined_macros = \ - - exclude_file_name_regexp--sc_prohibit_path_max_allocation = \ - ^libparted/arch/beos\.c$$ -+ -+exclude_file_name_regexp--sc_unmarked_diagnostics = ^tests/print-max\.c$$ -diff --git a/tests/print-max.c b/tests/print-max.c -index 7560d49..41aa8c6 100644 ---- a/tests/print-max.c -+++ b/tests/print-max.c -@@ -2,9 +2,11 @@ - #include - #include - #include -+#include - - #include "closeout.h" - #include "progname.h" -+#include "error.h" - - int - main (int argc, char **argv) -@@ -26,8 +28,16 @@ main (int argc, char **argv) - PedSector max_length = ped_disk_max_partition_length (disk); - PedSector max_start_sector = ped_disk_max_partition_start_sector (disk); - -+ if (!ped_device_open(dev)) -+ error (EXIT_FAILURE, errno, "failed to open %s\n", dev_name); -+ int max_n_partitions; -+ bool ok = ped_disk_get_max_supported_partition_count (disk, -+ &max_n_partitions); -+ - printf ("max len: %llu\n", (unsigned long long) max_length); - printf ("max start sector: %llu\n", (unsigned long long) max_start_sector); -+ printf ("max number of partitions: %d\n", -+ ok ? max_n_partitions : -1); - - ped_disk_destroy (disk); - ped_device_destroy (dev); -diff --git a/tests/t9021-maxima.sh b/tests/t9021-maxima.sh -index 0570585..ca10d17 100755 ---- a/tests/t9021-maxima.sh -+++ b/tests/t9021-maxima.sh -@@ -23,6 +23,27 @@ dev=dev-file - PATH="..:$PATH" - export PATH - -+max_n_partitions() -+{ -+ case $1 in -+ -+ # Technically, msdos partition tables have no limit on the maximum number -+ # of partitions, but we pretend it is 64 due to implementation details. -+ msdos) m=64;; -+ -+ gpt) m=128;; -+ dvh) m=16;; -+ sun) m=8;; -+ mac) m=65536;; -+ bsd) m=8;; -+ amiga) m=128;; -+ loop) m=1;; -+ pc98) case $ss in 512) m=16;; *) m=64;; esac;; -+ *) warn_ invalid partition table type: $1 1>&2; exit 1;; -+ esac -+ echo $m -+} -+ - # FIXME: add aix when/if it's supported again - for t in msdos gpt dvh sun mac bsd amiga loop pc98; do - echo $t -@@ -40,8 +61,11 @@ for t in msdos gpt dvh sun mac bsd amiga loop pc98; do - esac - - print-max $dev > out 2>&1 || fail=1 -+ m=$(max_n_partitions $t) || fail=1 - printf '%s\n' "max len: $max_len" \ -- "max start sector: $max_start" > exp || fail=1 -+ "max start sector: $max_start" \ -+ "max number of partitions: $m" \ -+ > exp || fail=1 - compare exp out || fail=1 - done - --- -1.9.3 - diff --git a/0007-maint-avoid-new-syntax-check-failure-re-xref.patch b/0007-maint-avoid-new-syntax-check-failure-re-xref.patch deleted file mode 100644 index 2487fbd..0000000 --- a/0007-maint-avoid-new-syntax-check-failure-re-xref.patch +++ /dev/null @@ -1,51 +0,0 @@ -From 89377f99947391c081df6dad27edf6ac3daec5c0 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Tue, 28 Aug 2012 19:47:54 +0200 -Subject: [PATCH 007/131] maint: avoid new syntax-check failure re @xref - -* doc/parted.texi: Adjust @xref usage: it must be used only -at start of sentence. -* doc/parted-pt_BR.texi: Likewise. ---- - doc/parted-pt_BR.texi | 4 ++-- - doc/parted.texi | 2 +- - 2 files changed, 3 insertions(+), 3 deletions(-) - -diff --git a/doc/parted-pt_BR.texi b/doc/parted-pt_BR.texi -index 8eb5cec..8878f83 100644 ---- a/doc/parted-pt_BR.texi -+++ b/doc/parted-pt_BR.texi -@@ -1094,7 +1094,7 @@ de sistemas operacionais Microsoft. - - @item raid - (MSDOS) - este sinalizador pode ser habilitado para dizer ao Linux que --essa partição é uma partição de software RAID @xref{LVM e RAID}. -+essa partição é uma partição de software RAID. @xref{LVM e RAID}. - - @item LVM - (MSDOS) - este sinalizador pode ser habilitado para dizer à partição -@@ -1994,7 +1994,7 @@ mudan - com o kernel 2.4, e quando nós adicionarmos suporte a ele.) - - Se você quer redimensionar sua partição root ou de boot, use um disco --de boot @xref{Discos de boot do Parted}, ou use o redimensionador -+de boot @pxref{Discos de boot do Parted}, ou use o redimensionador - online do Andreas Dilger, incluído no pacote ext2resize @ref{Ext2}. - - @menu -diff --git a/doc/parted.texi b/doc/parted.texi -index 6561d0e..1601151 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -348,7 +348,7 @@ specify the location in ``G''). Use the sector unit ``s'' to specify exact - locations. With parted-2.4 and newer, - IEC binary units like ``MiB'', ``GiB'', ``TiB'', etc., specify - exact locations as well. --See @xref{IEC binary units}. -+@xref{IEC binary units}. - - If you don't give a parameter to a command, Parted will prompt you for it. - For example: --- -1.9.3 - diff --git a/0008-maint-don-t-prohibit-strncpy-just-yet.patch b/0008-maint-don-t-prohibit-strncpy-just-yet.patch deleted file mode 100644 index 833c958..0000000 --- a/0008-maint-don-t-prohibit-strncpy-just-yet.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 00a5736ff2220229d75d4259c582ae0a62539915 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Tue, 28 Aug 2012 19:49:25 +0200 -Subject: [PATCH 008/131] maint: don't prohibit strncpy just yet - -* cfg.mk (local-checks-to-skip): Add sc_prohibit_strncpy, -so that we do not yet enable the strncpy prohibition. -There are many uses, and it will be a lot of work to remove -all of them. ---- - cfg.mk | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/cfg.mk b/cfg.mk -index 45d2ac2..3d3014c 100644 ---- a/cfg.mk -+++ b/cfg.mk -@@ -34,6 +34,7 @@ local-checks-to-skip = \ - sc_error_message_period \ - sc_file_system \ - sc_prohibit_strcmp \ -+ sc_prohibit_strncpy \ - sc_prohibit_atoi_atof \ - sc_require_test_exit_idiom \ - sc_space_tab \ --- -1.9.3 - diff --git a/0009-build-update-gnulib-bootstrap-and-init.sh.patch b/0009-build-update-gnulib-bootstrap-and-init.sh.patch deleted file mode 100644 index b3ccb14..0000000 --- a/0009-build-update-gnulib-bootstrap-and-init.sh.patch +++ /dev/null @@ -1,576 +0,0 @@ -From 92154e8dfb35c70f6792c4efed9cd97b4c84cbcb Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Tue, 28 Aug 2012 19:50:48 +0200 -Subject: [PATCH 009/131] build: update gnulib, bootstrap and init.sh - ---- - bootstrap | 267 ++++++++++++++++++++++++++++++++++++++-------------------- - gnulib | 2 +- - tests/init.sh | 13 ++- - 3 files changed, 185 insertions(+), 97 deletions(-) - -diff --git a/bootstrap b/bootstrap -index 31eb651..e3e270b 100755 ---- a/bootstrap -+++ b/bootstrap -@@ -1,6 +1,6 @@ - #! /bin/sh - # Print a version string. --scriptversion=2012-02-11.09; # UTC -+scriptversion=2012-07-19.14; # UTC - - # Bootstrap this package from checked-out sources. - -@@ -36,6 +36,10 @@ nl=' - LC_ALL=C - export LC_ALL - -+# Ensure that CDPATH is not set. Otherwise, the output from cd -+# would cause trouble in at least one use below. -+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH -+ - local_gl_dir=gl - - me=$0 -@@ -73,6 +77,33 @@ Running without arguments will suffice in most cases. - EOF - } - -+# warnf_ FORMAT-STRING ARG1... -+warnf_ () -+{ -+ warnf_format_=$1 -+ shift -+ nl=' -+' -+ case $* in -+ *$nl*) me_=$(printf "$me"|tr "$nl|" '??') -+ printf "$warnf_format_" "$@" | sed "s|^|$me_: |" ;; -+ *) printf "$me: $warnf_format_" "$@" ;; -+ esac >&2 -+} -+ -+# warn_ WORD1... -+warn_ () -+{ -+ # If IFS does not start with ' ', set it and emit the warning in a subshell. -+ case $IFS in -+ ' '*) warnf_ '%s\n' "$*";; -+ *) (IFS=' '; warn_ "$@");; -+ esac -+} -+ -+# die WORD1... -+die() { warn_ "$@"; exit 1; } -+ - # Configuration. - - # Name of the Makefile.am -@@ -126,7 +157,8 @@ extract_package_name=' - p - } - ' --package=`sed -n "$extract_package_name" configure.ac` || exit -+package=$(sed -n "$extract_package_name" configure.ac) \ -+ || die 'cannot find package name in configure.ac' - gnulib_name=lib$package - - build_aux=build-aux -@@ -182,6 +214,8 @@ use_git=true - # otherwise find the first of the NAMES that can be run (i.e., - # supports --version). If found, set ENVVAR to the program name, - # die otherwise. -+# -+# FIXME: code duplication, see also gnu-web-doc-update. - find_tool () - { - find_tool_envvar=$1 -@@ -199,19 +233,15 @@ find_tool () - else - find_tool_error_prefix="\$$find_tool_envvar: " - fi -- if test x"$find_tool_res" = x; then -- echo >&2 "$me: one of these is required: $find_tool_names" -- exit 1 -- fi -- ($find_tool_res --version /dev/null 2>&1 || { -- echo >&2 "$me: ${find_tool_error_prefix}cannot run $find_tool_res --version" -- exit 1 -- } -+ test x"$find_tool_res" != x \ -+ || die "one of these is required: $find_tool_names" -+ ($find_tool_res --version /dev/null 2>&1 \ -+ || die "${find_tool_error_prefix}cannot run $find_tool_res --version" - eval "$find_tool_envvar=\$find_tool_res" - eval "export $find_tool_envvar" - } - --# Find sha1sum, named gsha1sum on MacPorts, and shasum on MacOS 10.6. -+# Find sha1sum, named gsha1sum on MacPorts, and shasum on Mac OS X 10.6. - find_tool SHA1SUM sha1sum gsha1sum shasum - - # Override the default configuration, if necessary. -@@ -226,7 +256,6 @@ esac - test -z "${gnulib_extra_files}" && \ - gnulib_extra_files=" - $build_aux/install-sh -- $build_aux/missing - $build_aux/mdate-sh - $build_aux/texinfo.tex - $build_aux/depcomp -@@ -252,7 +281,7 @@ do - usage - exit;; - --gnulib-srcdir=*) -- GNULIB_SRCDIR=`expr "X$option" : 'X--gnulib-srcdir=\(.*\)'`;; -+ GNULIB_SRCDIR=${option#--gnulib-srcdir=};; - --skip-po) - SKIP_PO=t;; - --force) -@@ -266,21 +295,15 @@ do - --no-git) - use_git=false;; - *) -- echo >&2 "$0: $option: unknown option" -- exit 1;; -+ die "$option: unknown option";; - esac - done - --if $use_git || test -d "$GNULIB_SRCDIR"; then -- : --else -- echo "$0: Error: --no-git requires --gnulib-srcdir" >&2 -- exit 1 --fi -+$use_git || test -d "$GNULIB_SRCDIR" \ -+ || die "Error: --no-git requires --gnulib-srcdir" - - if test -n "$checkout_only_file" && test ! -r "$checkout_only_file"; then -- echo "$0: Bootstrapping from a non-checked-out distribution is risky." >&2 -- exit 1 -+ die "Bootstrapping from a non-checked-out distribution is risky." - fi - - # Ensure that lines starting with ! sort last, per gitignore conventions -@@ -303,10 +326,10 @@ insert_sorted_if_absent() { - file=$1 - str=$2 - test -f $file || touch $file -- echo "$str" | sort_patterns - $file | cmp - $file > /dev/null \ -+ echo "$str" | sort_patterns - $file | cmp -s - $file > /dev/null \ - || { echo "$str" | sort_patterns - $file > $file.bak \ - && mv $file.bak $file; } \ -- || exit 1 -+ || die "insert_sorted_if_absent $file $str: failed" - } - - # Adjust $PATTERN for $VC_IGNORE_FILE and insert it with -@@ -319,7 +342,7 @@ insert_vc_ignore() { - # A .gitignore entry that does not start with '/' applies - # recursively to subdirectories, so prepend '/' to every - # .gitignore entry. -- pattern=`echo "$pattern" | sed s,^,/,`;; -+ pattern=$(echo "$pattern" | sed s,^,/,);; - esac - insert_sorted_if_absent "$vc_ignore_file" "$pattern" - } -@@ -330,11 +353,8 @@ grep '^[ ]*AC_CONFIG_AUX_DIR(\['"$build_aux"'\])' configure.ac \ - >/dev/null && found_aux_dir=yes - grep '^[ ]*AC_CONFIG_AUX_DIR('"$build_aux"')' configure.ac \ - >/dev/null && found_aux_dir=yes --if test $found_aux_dir = no; then -- echo "$0: expected line not found in configure.ac. Add the following:" >&2 -- echo " AC_CONFIG_AUX_DIR([$build_aux])" >&2 -- exit 1 --fi -+test $found_aux_dir = yes \ -+ || die "configure.ac lacks 'AC_CONFIG_AUX_DIR([$build_aux])'; add it" - - # If $build_aux doesn't exist, create it now, otherwise some bits - # below will malfunction. If creating it, also mark it as ignored. -@@ -423,31 +443,48 @@ check_versions() { - $use_git || continue - fi - # Honor $APP variables ($TAR, $AUTOCONF, etc.) -- appvar=`echo $app | LC_ALL=C tr '[a-z]-' '[A-Z]_'` -+ appvar=$(echo $app | LC_ALL=C tr '[a-z]-' '[A-Z]_') - test "$appvar" = TAR && appvar=AMTAR - case $appvar in - GZIP) ;; # Do not use $GZIP: it contains gzip options. - *) eval "app=\${$appvar-$app}" ;; - esac -+ -+ # Handle the still-experimental Automake-NG programs specially. -+ # They remain named as the mainstream Automake programs ("automake", -+ # and "aclocal") to avoid gratuitous incompatibilities with -+ # pre-existing usages (by, say, autoreconf, or custom autogen.sh -+ # scripts), but correctly identify themselves (as being part of -+ # "GNU automake-ng") when asked their version. -+ case $app in -+ automake-ng|aclocal-ng) -+ app=${app%-ng} -+ ($app --version | grep '(GNU automake-ng)') >/dev/null 2>&1 || { -+ warn_ "Error: '$app' not found or not from Automake-NG" -+ ret=1 -+ continue -+ } ;; -+ esac - if [ "$req_ver" = "-" ]; then - # Merely require app to exist; not all prereq apps are well-behaved - # so we have to rely on $? rather than get_version. - $app --version >/dev/null 2>&1 - if [ 126 -le $? ]; then -- echo "$me: Error: '$app' not found" >&2 -+ warn_ "Error: '$app' not found" - ret=1 - fi - else - # Require app to produce a new enough version string. - inst_ver=$(get_version $app) - if [ ! "$inst_ver" ]; then -- echo "$me: Error: '$app' not found" >&2 -+ warn_ "Error: '$app' not found" - ret=1 - else - latest_ver=$(sort_ver $req_ver $inst_ver | cut -d' ' -f2) - if [ ! "$latest_ver" = "$inst_ver" ]; then -- echo "$me: Error: '$app' version == $inst_ver is too old" >&2 -- echo " '$app' version >= $req_ver is required" >&2 -+ warnf_ '%s\n' \ -+ "Error: '$app' version == $inst_ver is too old" \ -+ " '$app' version >= $req_ver is required" - ret=1 - fi - fi -@@ -492,10 +529,8 @@ esac - - # When we can deduce that gnulib-tool will require patch, - # and when patch is not already listed as a prerequisite, add it, too. --if test ! -d "$local_gl_dir" \ -- || find "$local_gl_dir" -name '*.diff' -exec false {} +; then -- : --else -+if test -d "$local_gl_dir" \ -+ && ! find "$local_gl_dir" -name '*.diff' -exec false {} +; then - case $buildreq in - *patch*) ;; - *) buildreq="patch - -@@ -506,11 +541,10 @@ fi - if ! printf "$buildreq" | check_versions; then - echo >&2 - if test -f README-prereq; then -- echo "$0: See README-prereq for how to get the prerequisite programs" >&2 -+ die "See README-prereq for how to get the prerequisite programs" - else -- echo "$0: Please install the prerequisite programs" >&2 -+ die "Please install the prerequisite programs" - fi -- exit 1 - fi - - echo "$0: Bootstrapping from checked-out $package sources..." -@@ -539,7 +573,7 @@ git_modules_config () { - test -f .gitmodules && git config --file .gitmodules "$@" - } - --gnulib_path=`git_modules_config submodule.gnulib.path` -+gnulib_path=$(git_modules_config submodule.gnulib.path) - test -z "$gnulib_path" && gnulib_path=gnulib - - # Get gnulib files. -@@ -612,10 +646,10 @@ download_po_files() { - subdir=$1 - domain=$2 - echo "$me: getting translations into $subdir for $domain..." -- cmd=`printf "$po_download_command_format" "$domain" "$subdir"` -+ cmd=$(printf "$po_download_command_format" "$domain" "$subdir") - eval "$cmd" && return - # Fallback to HTTP. -- cmd=`printf "$po_download_command_format2" "$subdir" "$domain"` -+ cmd=$(printf "$po_download_command_format2" "$subdir" "$domain") - eval "$cmd" - } - -@@ -638,7 +672,7 @@ update_po_files() { - && ls "$ref_po_dir"/*.po 2>/dev/null | - sed 's|.*/||; s|\.po$||' > "$po_dir/LINGUAS" || return - -- langs=`cd $ref_po_dir && echo *.po|sed 's/\.po//g'` -+ langs=$(cd $ref_po_dir && echo *.po | sed 's/\.po//g') - test "$langs" = '*' && langs=x - for po in $langs; do - case $po in x) continue;; esac -@@ -675,18 +709,18 @@ symlink_to_dir() - - # If the destination directory doesn't exist, create it. - # This is required at least for "lib/uniwidth/cjk.h". -- dst_dir=`dirname "$dst"` -+ dst_dir=$(dirname "$dst") - if ! test -d "$dst_dir"; then - mkdir -p "$dst_dir" - - # If we've just created a directory like lib/uniwidth, - # tell version control system(s) it's ignorable. - # FIXME: for now, this does only one level -- parent=`dirname "$dst_dir"` -+ parent=$(dirname "$dst_dir") - for dot_ig in x $vc_ignore; do - test $dot_ig = x && continue - ig=$parent/$dot_ig -- insert_vc_ignore $ig `echo "$dst_dir"|sed 's,.*/,,'` -+ insert_vc_ignore $ig "${dst_dir##*/}" - done - fi - -@@ -710,10 +744,10 @@ symlink_to_dir() - # so that broken tools aren't confused into skipping needed builds. See - # . - test -h "$dst" && -- src_ls=`ls -diL "$src" 2>/dev/null` && set $src_ls && src_i=$1 && -- dst_ls=`ls -diL "$dst" 2>/dev/null` && set $dst_ls && dst_i=$1 && -+ src_ls=$(ls -diL "$src" 2>/dev/null) && set $src_ls && src_i=$1 && -+ dst_ls=$(ls -diL "$dst" 2>/dev/null) && set $dst_ls && dst_i=$1 && - test "$src_i" = "$dst_i" && -- both_ls=`ls -dt "$src" "$dst"` && -+ both_ls=$(ls -dt "$src" "$dst") && - test "X$both_ls" = "X$dst$nl$src" || { - dot_dots= - case $src in -@@ -721,11 +755,10 @@ symlink_to_dir() - *) - case /$dst/ in - *//* | */../* | */./* | /*/*/*/*/*/) -- echo >&2 "$me: invalid symlink calculation: $src -> $dst" -- exit 1;; -- /*/*/*/*/) dot_dots=../../../;; -- /*/*/*/) dot_dots=../../;; -- /*/*/) dot_dots=../;; -+ die "invalid symlink calculation: $src -> $dst";; -+ /*/*/*/*/) dot_dots=../../../;; -+ /*/*/*/) dot_dots=../../;; -+ /*/*/) dot_dots=../;; - esac;; - esac - -@@ -736,6 +769,22 @@ symlink_to_dir() - } - } - -+version_controlled_file() { -+ parent=$1 -+ file=$2 -+ if test -d .git; then -+ git rm -n "$file" > /dev/null 2>&1 -+ elif test -d .svn; then -+ svn log -r HEAD "$file" > /dev/null 2>&1 -+ elif test -d CVS; then -+ grep -F "/${file##*/}/" "$parent/CVS/Entries" 2>/dev/null | -+ grep '^/[^/]*/[0-9]' > /dev/null -+ else -+ warn_ "no version control for $file?" -+ false -+ fi -+} -+ - # NOTE: we have to be careful to run both autopoint and libtoolize - # before gnulib-tool, since gnulib-tool is likely to provide newer - # versions of files "installed" by these two programs. -@@ -748,37 +797,54 @@ with_gettext=yes - grep '^[ ]*AM_GNU_GETTEXT_VERSION(' configure.ac >/dev/null || \ - with_gettext=no - --if test $with_gettext = yes; then -- # Released autopoint has the tendency to install macros that have been -- # obsoleted in current gnulib, so run this before gnulib-tool. -- echo "$0: $AUTOPOINT --force" -- $AUTOPOINT --force || exit --fi -+if test $with_gettext = yes || test $use_libtool = 1; then - --# Autoreconf runs aclocal before libtoolize, which causes spurious --# warnings if the initial aclocal is confused by the libtoolized --# (or worse out-of-date) macro directory. --if test $use_libtool = 1; then -- echo "running: $LIBTOOLIZE --copy --install" -- $LIBTOOLIZE --copy --install --fi -+ tempbase=.bootstrap$$ -+ trap "rm -f $tempbase.0 $tempbase.1" 1 2 13 15 - --version_controlled_file() { -- dir=$1 -- file=$2 -- found=no -- if test -d CVS; then -- grep -F "/$file/" $dir/CVS/Entries 2>/dev/null | -- grep '^/[^/]*/[0-9]' > /dev/null && found=yes -- elif test -d .git; then -- git rm -n "$dir/$file" > /dev/null 2>&1 && found=yes -- elif test -d .svn; then -- svn log -r HEAD "$dir/$file" > /dev/null 2>&1 && found=yes -- else -- echo "$me: no version control for $dir/$file?" >&2 -+ > $tempbase.0 > $tempbase.1 && -+ find . ! -type d -print | sort > $tempbase.0 || exit -+ -+ if test $with_gettext = yes; then -+ # Released autopoint has the tendency to install macros that have been -+ # obsoleted in current gnulib, so run this before gnulib-tool. -+ echo "$0: $AUTOPOINT --force" -+ $AUTOPOINT --force || exit - fi -- test $found = yes --} -+ -+ # Autoreconf runs aclocal before libtoolize, which causes spurious -+ # warnings if the initial aclocal is confused by the libtoolized -+ # (or worse out-of-date) macro directory. -+ # libtoolize 1.9b added the --install option; but we support back -+ # to libtoolize 1.5.22, where the install action was default. -+ if test $use_libtool = 1; then -+ install= -+ case $($LIBTOOLIZE --help) in -+ *--install*) install=--install ;; -+ esac -+ echo "running: $LIBTOOLIZE $install --copy" -+ $LIBTOOLIZE $install --copy -+ fi -+ -+ find . ! -type d -print | sort >$tempbase.1 -+ old_IFS=$IFS -+ IFS=$nl -+ for file in $(comm -13 $tempbase.0 $tempbase.1); do -+ IFS=$old_IFS -+ parent=${file%/*} -+ version_controlled_file "$parent" "$file" || { -+ for dot_ig in x $vc_ignore; do -+ test $dot_ig = x && continue -+ ig=$parent/$dot_ig -+ insert_vc_ignore "$ig" "${file##*/}" -+ done -+ } -+ done -+ IFS=$old_IFS -+ -+ rm -f $tempbase.0 $tempbase.1 -+ trap - 1 2 13 15 -+fi - - # Import from gnulib. - -@@ -804,11 +870,12 @@ echo "$0: $gnulib_tool $gnulib_tool_options --import ..." - $gnulib_tool $gnulib_tool_options --import $gnulib_modules && - - for file in $gnulib_files; do -- symlink_to_dir "$GNULIB_SRCDIR" $file || exit -+ symlink_to_dir "$GNULIB_SRCDIR" $file \ -+ || die "failed to symlink $file" - done - - bootstrap_post_import_hook \ -- || { echo >&2 "$me: bootstrap_post_import_hook failed"; exit 1; } -+ || die "bootstrap_post_import_hook failed" - - # Remove any dangling symlink matching "*.m4" or "*.[ch]" in some - # gnulib-populated directories. Such .m4 files would cause aclocal to fail. -@@ -836,16 +903,17 @@ echo "running: AUTOPOINT=true LIBTOOLIZE=true " \ - "$AUTORECONF --verbose --install $no_recursive -I $m4_base $ACLOCAL_FLAGS" - AUTOPOINT=true LIBTOOLIZE=true \ - $AUTORECONF --verbose --install $no_recursive -I $m4_base $ACLOCAL_FLAGS \ -- || exit 1 -+ || die "autoreconf failed" - - # Get some extra files from gnulib, overriding existing files. - for file in $gnulib_extra_files; do - case $file in - */INSTALL) dst=INSTALL;; -- build-aux/*) dst=$build_aux/`expr "$file" : 'build-aux/\(.*\)'`;; -+ build-aux/*) dst=$build_aux/${file#build-aux/};; - *) dst=$file;; - esac -- symlink_to_dir "$GNULIB_SRCDIR" $file $dst || exit -+ symlink_to_dir "$GNULIB_SRCDIR" $file $dst \ -+ || die "failed to symlink $file" - done - - if test $with_gettext = yes; then -@@ -861,7 +929,19 @@ if test $with_gettext = yes; then - a\ - '"$XGETTEXT_OPTIONS"' $${end_of_xgettext_options+} - } -- ' po/Makevars.template >po/Makevars || exit 1 -+ ' po/Makevars.template >po/Makevars \ -+ || die 'cannot generate po/Makevars' -+ -+ # If the 'gettext' module is in use, grab the latest Makefile.in.in. -+ # If only the 'gettext-h' module is in use, assume autopoint already -+ # put the correct version of this file into place. -+ case $gnulib_modules in -+ *gettext-h*) ;; -+ *gettext*) -+ cp $GNULIB_SRCDIR/build-aux/po/Makefile.in.in po/Makefile.in.in \ -+ || die "cannot create po/Makefile.in.in" -+ ;; -+ esac - - if test -d runtime-po; then - # Similarly for runtime-po/Makevars, but not quite the same. -@@ -875,7 +955,8 @@ if test $with_gettext = yes; then - a\ - '"$XGETTEXT_OPTIONS_RUNTIME"' $${end_of_xgettext_options+} - } -- ' po/Makevars.template >runtime-po/Makevars || exit 1 -+ ' po/Makevars.template >runtime-po/Makevars \ -+ || die 'cannot generate runtime-po/Makevars' - - # Copy identical files from po to runtime-po. - (cd po && cp -p Makefile.in.in *-quot *.header *.sed *.sin ../runtime-po) -diff --git a/gnulib b/gnulib -index 50bb21e..e1abd50 160000 ---- a/gnulib -+++ b/gnulib -@@ -1 +1 @@ --Subproject commit 50bb21eab7dfc87bbfcbc75f0232407110cdd296 -+Subproject commit e1abd50b01d6bd61bd0c996ca17378cd569c0aa1 -diff --git a/tests/init.sh b/tests/init.sh -index ae86714..5f6e638 100644 ---- a/tests/init.sh -+++ b/tests/init.sh -@@ -207,6 +207,14 @@ else - fi - fi - -+# If this is bash, turn off all aliases. -+test -n "$BASH_VERSION" && unalias -a -+ -+# Note that when supporting $EXEEXT (transparently mapping from PROG_NAME to -+# PROG_NAME.exe), we want to support hyphen-containing names like test-acos. -+# That is part of the shell-selection test above. Why use aliases rather -+# than functions? Because support for hyphen-containing aliases is more -+# widespread than that for hyphen-containing function names. - test -n "$EXEEXT" && shopt -s expand_aliases - - # Enable glibc's malloc-perturbing option. -@@ -403,8 +411,7 @@ path_prepend_ () - case $path_dir_ in - '') fail_ "invalid path dir: '$1'";; - /*) abs_path_dir_=$path_dir_;; -- *) abs_path_dir_=`cd "$initial_cwd_/$path_dir_" && echo "$PWD"` \ -- || fail_ "invalid path dir: $path_dir_";; -+ *) abs_path_dir_=$initial_cwd_/$path_dir_;; - esac - case $abs_path_dir_ in - *:*) fail_ "invalid path dir: '$abs_path_dir_'";; -@@ -440,7 +447,7 @@ setup_ () - pfx_=`testdir_prefix_` - test_dir_=`mktempd_ "$initial_cwd_" "$pfx_-$ME_.XXXX"` \ - || fail_ "failed to create temporary directory in $initial_cwd_" -- cd "$test_dir_" -+ cd "$test_dir_" || fail_ "failed to cd to temporary directory" - - # As autoconf-generated configure scripts do, ensure that IFS - # is defined initially, so that saving and restoring $IFS works. --- -1.9.3 - diff --git a/0010-build-prefer-AM_CPPFLAGS-over-INCLUDES.patch b/0010-build-prefer-AM_CPPFLAGS-over-INCLUDES.patch deleted file mode 100644 index 3bc2760..0000000 --- a/0010-build-prefer-AM_CPPFLAGS-over-INCLUDES.patch +++ /dev/null @@ -1,86 +0,0 @@ -From a185e958b5614ea7e606e85d3de879c5ffc127c0 Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:13 +0200 -Subject: [PATCH 010/131] build: prefer $(AM_CPPFLAGS) over $(INCLUDES) - -The latter is obsolete, and might be removed in future Automake versions. -Moreover, it's already been removed in Automake-NG, so its use would make -a port to Automake-NG more difficult. - -* parted/Makefile.am (INCLUDES): Rename ... -(AM_CPPFLAGS): ... like this. -* partprobe/Makefile.am: Likewise. -* libparted/fs/Makefile.am: Likewise. -* libparted/Makefile.am: Likewise. -* libparted/labels/Makefile.am: Likewise. - -Copyright-paperwork-exempt: yes ---- - libparted/Makefile.am | 2 +- - libparted/fs/Makefile.am | 2 +- - libparted/labels/Makefile.am | 2 +- - parted/Makefile.am | 2 +- - partprobe/Makefile.am | 2 +- - 5 files changed, 5 insertions(+), 5 deletions(-) - -diff --git a/libparted/Makefile.am b/libparted/Makefile.am -index 7cf35b2..bdc7976 100644 ---- a/libparted/Makefile.am -+++ b/libparted/Makefile.am -@@ -62,4 +62,4 @@ libparted_la_LIBADD = \ - - EXTRA_DIST = mbr.s - --INCLUDES = $(partedincludedir) $(INTLINCS) -+AM_CPPFLAGS = $(partedincludedir) $(INTLINCS) -diff --git a/libparted/fs/Makefile.am b/libparted/fs/Makefile.am -index 8d48ea1..7fe364a 100644 ---- a/libparted/fs/Makefile.am -+++ b/libparted/fs/Makefile.am -@@ -114,7 +114,7 @@ libparted_fs_resize_la_SOURCES = \ - r/hfs/reloc_plus.c \ - r/hfs/reloc_plus.h - --INCLUDES = \ -+AM_CPPFLAGS = \ - -I$(top_srcdir)/libparted/labels \ - $(partedincludedir) \ - $(INTLINCS) -diff --git a/libparted/labels/Makefile.am b/libparted/labels/Makefile.am -index 7fe347b..ec8abeb 100644 ---- a/libparted/labels/Makefile.am -+++ b/libparted/labels/Makefile.am -@@ -37,7 +37,7 @@ liblabels_la_SOURCES = \ - - liblabels_la_LIBADD = $(OS_LIBS) $(INTLLIBS) - --INCLUDES = $(partedincludedir) $(INTLINCS) -+AM_CPPFLAGS = $(partedincludedir) $(INTLINCS) - - BUILT_SOURCES = pt-limit.c - MAINTAINERCLEANFILES = $(BUILT_SOURCES) -diff --git a/parted/Makefile.am b/parted/Makefile.am -index 0b23693..e7bba2e 100644 ---- a/parted/Makefile.am -+++ b/parted/Makefile.am -@@ -48,6 +48,6 @@ parted_LDFLAGS = $(PARTEDLDFLAGS) - # Tell the linker to omit references to unused shared libraries. - parted_LDFLAGS += $(IGNORE_UNUSED_LIBRARIES_CFLAGS) - --INCLUDES = $(partedincludedir) $(INTLINCS) -+AM_CPPFLAGS = $(partedincludedir) $(INTLINCS) - - MAINTAINERCLEANFILES += Makefile.in -diff --git a/partprobe/Makefile.am b/partprobe/Makefile.am -index dbe2c9f..c0304a0 100644 ---- a/partprobe/Makefile.am -+++ b/partprobe/Makefile.am -@@ -13,4 +13,4 @@ partprobe_LDADD = \ - - partprobe_LDFLAGS = $(PARTEDLDFLAGS) - --INCLUDES = $(partedincludedir) $(INTLINCS) -+AM_CPPFLAGS = $(partedincludedir) $(INTLINCS) --- -1.9.3 - diff --git a/0011-build-don-t-list-files-with-unknown-suffix-in-_SOURC.patch b/0011-build-don-t-list-files-with-unknown-suffix-in-_SOURC.patch deleted file mode 100644 index 37251e9..0000000 --- a/0011-build-don-t-list-files-with-unknown-suffix-in-_SOURC.patch +++ /dev/null @@ -1,48 +0,0 @@ -From 605c53ad0f209b9f62a15c3f89a9930860153489 Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:14 +0200 -Subject: [PATCH 011/131] build: don't list files with unknown suffix in - _SOURCES - -While this works with mainline Automake (which blindly treats source -files with an unknown extension as if they were header files), it is -undocumented (albeit admittedly unlikely to change). Moreover, it no -longer works with Automake-NG (and that's by design), so the use of -such feature would make a port to Automake-NG more difficult. - -* libparted/labels/Makefile.am (liblabels_la_SOURCES): ... don't -list 'pt-limit.gperf' here; rather ... -(EXTRA_DIST): ... list 'pt-limit.c' and 'pt-limit.gperf' here. -(EXTRA_DIST, BUILT_SOURCES): Enhance few comments. - -Copyright-paperwork-exempt: yes ---- - libparted/labels/Makefile.am | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/libparted/labels/Makefile.am b/libparted/labels/Makefile.am -index ec8abeb..f4e4d27 100644 ---- a/libparted/labels/Makefile.am -+++ b/libparted/labels/Makefile.am -@@ -39,10 +39,11 @@ liblabels_la_LIBADD = $(OS_LIBS) $(INTLLIBS) - - AM_CPPFLAGS = $(partedincludedir) $(INTLINCS) - -+# Included by 'pt-tools.c', so needs to be built early. - BUILT_SOURCES = pt-limit.c - MAINTAINERCLEANFILES = $(BUILT_SOURCES) --liblabels_la_SOURCES += pt-limit.gperf --EXTRA_DIST = $(BUILT_SOURCES) -+# DOn't add this to '_SOURCES', because it's not to be compiled! -+EXTRA_DIST= pt-limit.c - - GPERF = gperf - GPERF_OPTIONS = \ -@@ -55,3 +56,4 @@ pt-limit.c: pt-limit.gperf - > $@-tmp - chmod a-w $@-tmp - mv $@-tmp $@ -+EXTRA_DIST += pt-limit.gperf --- -1.9.3 - diff --git a/0012-build-prefer-pattern-rules-over-suffix-rules.patch b/0012-build-prefer-pattern-rules-over-suffix-rules.patch deleted file mode 100644 index 52d8f40..0000000 --- a/0012-build-prefer-pattern-rules-over-suffix-rules.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 904a8d31d2906e8e653d670e508c4c6bd4b264c1 Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:15 +0200 -Subject: [PATCH 012/131] build: prefer pattern rules over suffix rules - -That is acceptable, because the GNU parted build system already -requires GNU make anyway: the $(subst ...) built-in is used in the -common recipe for the 'ss-1024', 'ss-2048' and 'ss-4096' targets -in Makefile.am. - -* include/parted/Makefile.am (.in.h.h): Rename ... -(%.h: %.in.h): ... as this pattern rule. -(SUFFIXES): Delete, no more needed. - -Copyright-paperwork-exempt: yes ---- - include/parted/Makefile.am | 3 +-- - 1 file changed, 1 insertion(+), 2 deletions(-) - -diff --git a/include/parted/Makefile.am b/include/parted/Makefile.am -index 19236f0..6f808c6 100644 ---- a/include/parted/Makefile.am -+++ b/include/parted/Makefile.am -@@ -44,8 +44,7 @@ subst_pure_attr = \ - - $(BUILT_SOURCES): Makefile.am - --SUFFIXES = .in.h .h --.in.h.h: -+%.h: %.in.h - $(AM_V_GEN)rm -f $@ $@-t - $(AM_V_at)perl -p \ - -e '$(subst_const_attr);' \ --- -1.9.3 - diff --git a/0013-build-enable-subdir-objects-Automake-option-globally.patch b/0013-build-enable-subdir-objects-Automake-option-globally.patch deleted file mode 100644 index 57de0b4..0000000 --- a/0013-build-enable-subdir-objects-Automake-option-globally.patch +++ /dev/null @@ -1,53 +0,0 @@ -From 803b2f58760ed82e5eb182df75ba18c00c9f43bf Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:16 +0200 -Subject: [PATCH 013/131] build: enable subdir-objects Automake option globally - -That option is enabled unconditionally in Automake-NG, and enabling -it also for mainline Automake will help to ensure no unexpected -incompatibilities is introduced in a potential port to Automake-NG. - -Moreover, if we have a source file 'sub/foo.c', having it compiled -in 'sub/foo.o' rather than in 'foo.o' is undeniably cleaner and more -natural. - -* configure.ac (AM_INIT_AUTOMAKE): Add 'subdir-objects'. -* libparted/fs/Makefile.am (AUTOMAKE_OPTIONS): No need to declare -'subdir-objects' explicitly now. - -Copyright-paperwork-exempt: yes ---- - configure.ac | 3 ++- - libparted/fs/Makefile.am | 2 -- - 2 files changed, 2 insertions(+), 3 deletions(-) - -diff --git a/configure.ac b/configure.ac -index 1444279..49ef75c 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -52,7 +52,8 @@ AC_SUBST([LT_CURRENT]) - AC_SUBST([LT_REVISION]) - AC_SUBST([LT_AGE]) - --AM_INIT_AUTOMAKE([1.11 no-dist-gzip dist-xz color-tests parallel-tests]) -+AM_INIT_AUTOMAKE([1.11 no-dist-gzip dist-xz color-tests parallel-tests -+ subdir-objects]) - AM_SILENT_RULES([yes]) # make --enable-silent-rules the default. - - AC_CANONICAL_HOST -diff --git a/libparted/fs/Makefile.am b/libparted/fs/Makefile.am -index 7fe364a..064f11a 100644 ---- a/libparted/fs/Makefile.am -+++ b/libparted/fs/Makefile.am -@@ -3,8 +3,6 @@ - # - # This file may be modified and/or distributed without restriction. - --AUTOMAKE_OPTIONS = subdir-objects -- - partedincludedir = -I$(top_builddir)/include -I$(top_srcdir)/include - - AM_CFLAGS = $(WARN_CFLAGS) --- -1.9.3 - diff --git a/0014-tests-prefer-AM_TESTS_ENVIRONMENT-over-TESTS_ENVIRON.patch b/0014-tests-prefer-AM_TESTS_ENVIRONMENT-over-TESTS_ENVIRON.patch deleted file mode 100644 index 9471c6d..0000000 --- a/0014-tests-prefer-AM_TESTS_ENVIRONMENT-over-TESTS_ENVIRON.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 2bd66d7d3e5a1924c65c051d4b639c5ab48bbb99 Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:17 +0200 -Subject: [PATCH 014/131] tests: prefer AM_TESTS_ENVIRONMENT over - TESTS_ENVIRONMENT - -The latter should be reserved for user overrides. - -* tests/Makefile.am (TESTS_ENVIRONMENT): Rename ... -(AM_TESTS_ENVIRONMENT): ... like this. - -Copyright-paperwork-exempt: yes ---- - tests/Makefile.am | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 1264812..33e8f8e 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -96,7 +96,7 @@ sep = $(PATH_SEPARATOR) - # variables that can perturb tests are unset or set to expected values. - # The rest are envvar settings that propagate build-related Makefile - # variables to test scripts. --TESTS_ENVIRONMENT = \ -+AM_TESTS_ENVIRONMENT = \ - tmp__=$$TMPDIR; test -d "$$tmp__" || tmp__=.; \ - TMPDIR=$$tmp__; export TMPDIR; \ - export \ --- -1.9.3 - diff --git a/0015-tests-remove-unused-AM_TESTS_ENVIRONMENT-entries.patch b/0015-tests-remove-unused-AM_TESTS_ENVIRONMENT-entries.patch deleted file mode 100644 index 9f40362..0000000 --- a/0015-tests-remove-unused-AM_TESTS_ENVIRONMENT-entries.patch +++ /dev/null @@ -1,41 +0,0 @@ -From af4d0f5706740848c3fef67a7ea0b78cf31ddb90 Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:18 +0200 -Subject: [PATCH 015/131] tests: remove unused AM_TESTS_ENVIRONMENT entries - -Probably a copy&paste errors, likely from the TESTS_ENVIRONMENT -definition in the 'tests/Makefile.am' in GNU coreutils. - -* tests/Makefile.am (AM_TESTS_ENVIRONMENT): Don't define nor export -any of the variables PREFERABLY_POSIX_SHELL, REPLACE_GETCWD, CC, -MAKE, PERL. - -Copyright-paperwork-exempt: yes ---- - tests/Makefile.am | 5 ----- - 1 file changed, 5 deletions(-) - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 33e8f8e..c97400b 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -107,16 +107,11 @@ AM_TESTS_ENVIRONMENT = \ - srcdir='$(srcdir)' \ - top_srcdir='$(top_srcdir)' \ - AWK='$(AWK)' \ -- CC='$(CC)' \ -- MAKE=$(MAKE) \ - PACKAGE_BUGREPORT='$(PACKAGE_BUGREPORT)' \ - PACKAGE_VERSION=$(PACKAGE_VERSION) \ - CONFIG_HEADER='$(abs_top_builddir)/lib/config.h' \ - ENABLE_DEVICE_MAPPER=$(ENABLE_DEVICE_MAPPER) \ - PARTED_TEST_NAME=`basename '$(abs_srcdir)'`,`echo $$tst|sed 's,^\./,,;s,/,-,g'`\ -- PERL='$(PERL)' \ -- PREFERABLY_POSIX_SHELL='$(PREFERABLY_POSIX_SHELL)' \ -- REPLACE_GETCWD=$(REPLACE_GETCWD) \ - PATH='$(abs_top_builddir)/parted$(PATH_SEPARATOR)'"$$PATH" \ - VERSION=$(VERSION) \ - ; 9>&2 --- -1.9.3 - diff --git a/0016-build-require-Automake-1.11.6.patch b/0016-build-require-Automake-1.11.6.patch deleted file mode 100644 index 3844f76..0000000 --- a/0016-build-require-Automake-1.11.6.patch +++ /dev/null @@ -1,51 +0,0 @@ -From b2338d71549462c1dfbb434111b5c46701f54261 Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:19 +0200 -Subject: [PATCH 016/131] build: require Automake >= 1.11.6 - -Now that we use AM_TESTS_ENVIRONMENT, we should require at least -Automake >= 1.11.2; but since all the Automake version until 1.11.5 -are vulnerable to CVE-2012-3386: - - - -it's even better to require 1.11.6. - -* configure.ac (AM_INIT_AUTOMAKE): Bump version requirement to 1.11.6. -* bootstrap.conf ($buildreq): Likewise. - -Copyright-paperwork-exempt: yes ---- - bootstrap.conf | 2 +- - configure.ac | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/bootstrap.conf b/bootstrap.conf -index b4456b2..39a5506 100644 ---- a/bootstrap.conf -+++ b/bootstrap.conf -@@ -130,7 +130,7 @@ mkdir -p gnulib-tests - # Build prerequisites - buildreq="\ - autoconf 2.61 --automake 1.11 -+automake 1.11.6 - autopoint - - bc - - gettext - -diff --git a/configure.ac b/configure.ac -index 49ef75c..832fc20 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -52,7 +52,7 @@ AC_SUBST([LT_CURRENT]) - AC_SUBST([LT_REVISION]) - AC_SUBST([LT_AGE]) - --AM_INIT_AUTOMAKE([1.11 no-dist-gzip dist-xz color-tests parallel-tests -+AM_INIT_AUTOMAKE([1.11.6 no-dist-gzip dist-xz color-tests parallel-tests - subdir-objects]) - AM_SILENT_RULES([yes]) # make --enable-silent-rules the default. - --- -1.9.3 - diff --git a/0017-maint-make-Autoconf-version-requirement-consistent.patch b/0017-maint-make-Autoconf-version-requirement-consistent.patch deleted file mode 100644 index 4a16d2f..0000000 --- a/0017-maint-make-Autoconf-version-requirement-consistent.patch +++ /dev/null @@ -1,29 +0,0 @@ -From c7c9978f0bbf05517437ccc76ea8eff5d811aaef Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:20 +0200 -Subject: [PATCH 017/131] maint: make Autoconf version requirement consistent - -* bootstrap.conf ($buildreq): Require Autoconf >= 2.63, not >= 2.61, -for consistency with what is done in AC_INIT in configure.ac - -Copyright-paperwork-exempt: yes ---- - bootstrap.conf | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/bootstrap.conf b/bootstrap.conf -index 39a5506..a5d5910 100644 ---- a/bootstrap.conf -+++ b/bootstrap.conf -@@ -129,7 +129,7 @@ mkdir -p gnulib-tests - - # Build prerequisites - buildreq="\ --autoconf 2.61 -+autoconf 2.63 - automake 1.11.6 - autopoint - - bc - --- -1.9.3 - diff --git a/0018-maint-tighten-per-version-requirement.patch b/0018-maint-tighten-per-version-requirement.patch deleted file mode 100644 index d76b2d7..0000000 --- a/0018-maint-tighten-per-version-requirement.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 0406b2ce14fb86ede506c51d6b603b1f4a1ff42d Mon Sep 17 00:00:00 2001 -From: Stefano Lattarini -Date: Thu, 30 Aug 2012 18:53:21 +0200 -Subject: [PATCH 018/131] maint: tighten per version requirement - -* bootstrap.conf ($buildreq): Require Perl >= 5.6 (not merely >= 5.5), -because that's the minimal version required by modern Automake and -Autoconf. - -Copyright-paperwork-exempt: yes ---- - bootstrap.conf | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/bootstrap.conf b/bootstrap.conf -index a5d5910..7f4ee53 100644 ---- a/bootstrap.conf -+++ b/bootstrap.conf -@@ -138,7 +138,7 @@ git 1.4.4 - gperf 3.0.3 - gzip - - makeinfo - --perl 5.5 -+perl 5.6 - rsync - - tar - - " --- -1.9.3 - diff --git a/0019-maint-remove-unnecessary-wcslen-use.patch b/0019-maint-remove-unnecessary-wcslen-use.patch deleted file mode 100644 index 01df01f..0000000 --- a/0019-maint-remove-unnecessary-wcslen-use.patch +++ /dev/null @@ -1,31 +0,0 @@ -From 464c0f9ae4af8346cd494c6434f4addabdd76e9d Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Tue, 11 Sep 2012 17:22:52 +0200 -Subject: [PATCH 019/131] maint: remove unnecessary wcslen use - -* parted/strlist.c (gettext_to_wchar): Tighten up test for -mbsrtowcs failure and remove unnecessary wcslen use. ---- - parted/strlist.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/parted/strlist.c b/parted/strlist.c -index d34fb56..1f90c0e 100644 ---- a/parted/strlist.c -+++ b/parted/strlist.c -@@ -112,10 +112,10 @@ gettext_to_wchar (const char* str) - - memset(&ps, 0, sizeof (ps)); - status = mbsrtowcs(result, &str, count, &ps); -- if (status == (size_t) -1) -+ if (str != NULL) - goto error; - -- result = xrealloc (result, (wcslen (result) + 1) * sizeof (wchar_t)); -+ result = xrealloc (result, (status + 1) * sizeof (wchar_t)); - return result; - - error: --- -1.9.3 - diff --git a/0020-tests-clarify-a-comment-_reading_-gpt-tables-on-tiny.patch b/0020-tests-clarify-a-comment-_reading_-gpt-tables-on-tiny.patch deleted file mode 100644 index 983f3bc..0000000 --- a/0020-tests-clarify-a-comment-_reading_-gpt-tables-on-tiny.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 1d67e37ef257d3d3847126f3b899b8b0e11aa186 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 12 Sep 2012 10:02:46 +0200 -Subject: [PATCH 020/131] tests: clarify a comment: _reading_ gpt tables on - tiny devices - -* tests/t0203-gpt-tiny-device-abort.sh: Clarify. ---- - tests/t0203-gpt-tiny-device-abort.sh | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/tests/t0203-gpt-tiny-device-abort.sh b/tests/t0203-gpt-tiny-device-abort.sh -index 7283c55..bf281ff 100644 ---- a/tests/t0203-gpt-tiny-device-abort.sh -+++ b/tests/t0203-gpt-tiny-device-abort.sh -@@ -1,6 +1,6 @@ - #!/bin/sh --# parted before 3.1 could abort for a pathologically small device with --# a valid primary GPT header but no room for the backup header. -+# parted before 3.1 could abort while reading a pathologically small device -+# with a valid primary GPT header but no room for the backup header. - - # Copyright (C) 2009-2012 Free Software Foundation, Inc. - --- -1.9.3 - diff --git a/0021-gpt-require-first_usable_LBA-last_usable_LBA.patch b/0021-gpt-require-first_usable_LBA-last_usable_LBA.patch deleted file mode 100644 index bd0756a..0000000 --- a/0021-gpt-require-first_usable_LBA-last_usable_LBA.patch +++ /dev/null @@ -1,31 +0,0 @@ -From 46d9108009ccb9ac567cc285a15efb05864932d5 Mon Sep 17 00:00:00 2001 -From: Davidlohr Bueso -Date: Tue, 11 Sep 2012 19:22:32 +0200 -Subject: [PATCH 021/131] gpt: require first_usable_LBA <= last_usable_LBA - -When verifying GPT header integrity, ensure that the -first usable LBA is no larger than the last usable LBA. -* libparted/labels/gpt.c (_header_is_valid): Reject a header -with last_usable < first_usable. ---- - libparted/labels/gpt.c | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 6032e3f..83e518f 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -653,6 +653,10 @@ _header_is_valid (PedDisk const *disk, GuidPartitionTableHeader_t *gpt, - if (first_usable < 3) - return 0; - -+ PedSector last_usable = PED_LE64_TO_CPU (gpt->LastUsableLBA); -+ if (last_usable < first_usable) -+ return 0; -+ - origcrc = gpt->HeaderCRC32; - gpt->HeaderCRC32 = 0; - if (pth_crc32 (dev, gpt, &crc) != 0) --- -1.9.3 - diff --git a/0022-tests-update-t7000-scripting.sh-to-avoid-new-FP.patch b/0022-tests-update-t7000-scripting.sh-to-avoid-new-FP.patch deleted file mode 100644 index 929dcd0..0000000 --- a/0022-tests-update-t7000-scripting.sh-to-avoid-new-FP.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 81faa9b3b957781871ec3ef0df6e357388f857a1 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 12 Sep 2012 20:34:48 +0200 -Subject: [PATCH 022/131] tests: update t7000-scripting.sh to avoid new FP - -* tests/t7000-scripting.sh: Use -34s as the endpoint, not -1s, -to avoid a spurious difference. Also, remove quoting artifacts. ---- - tests/t7000-scripting.sh | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/tests/t7000-scripting.sh b/tests/t7000-scripting.sh -index e64814b..859acda 100755 ---- a/tests/t7000-scripting.sh -+++ b/tests/t7000-scripting.sh -@@ -47,7 +47,7 @@ for mkpart in mkpart; do - dd if=/dev/zero of=testfile bs=${ss}c count=$N 2> /dev/null || fail=1 - - # Test the scripting mode of $mkpart. -- parted -s testfile -- mklabel gpt "$mkpart" p-name ext3 1s -1s > out 2>&1 -+ parted -s testfile -- mklabel gpt "$mkpart" p-name ext3 1s -34s > out 2>&1 - test $? = 1 || fail=1 - - # Compare the real error and the expected one -@@ -60,8 +60,8 @@ for mkpart in mkpart; do - dd if=/dev/zero of=testfile bs=${ss}c count=$N 2> /dev/null || fail=1 - # Test the interactive mode of $mkpart - echo n | \ -- parted ---pretend-input-tty testfile \ -- "mklabel gpt '$mkpart' p-name ext3 1s -1s" > out 2>&1 && fail=1 -+ parted ---pretend-input-tty -- testfile \ -+ mklabel gpt $mkpart p-name ext3 1s -34s > out 2>&1 && fail=1 - - # We have to format the output before comparing. - # normalize the actual output --- -1.9.3 - diff --git a/0023-gpt-permit-mklabel-gpt-on-a-67-sector-device.patch b/0023-gpt-permit-mklabel-gpt-on-a-67-sector-device.patch deleted file mode 100644 index cacf2e2..0000000 --- a/0023-gpt-permit-mklabel-gpt-on-a-67-sector-device.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 48f236f9cf1bbcd4c9cc29ebaecee7ed189580e3 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 12 Sep 2012 10:01:53 +0200 -Subject: [PATCH 023/131] gpt: permit "mklabel gpt" on a 67-sector device - -* libparted/labels/gpt.c (gpt_alloc): Correct checks in order to -allow creation of a GPT partition table on a 67-sector device. -The computation of the "data_end" sector number was one too low. -Whereas there are two sectors at the beginning of the disk (pMBR -and the GPT header sector), there is only one at the end: the -backup GPT header. That (67) is the size of the smallest GPT -partition table, allowing for *no* partition table sectors. ---- - libparted/labels/gpt.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 83e518f..564a889 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -501,11 +501,11 @@ gpt_alloc (const PedDevice *dev) - goto error; - - data_start = 2 + GPT_DEFAULT_PARTITION_ENTRY_ARRAY_SIZE / dev->sector_size; -- data_end = dev->length - 2 -+ data_end = dev->length - 1 - - GPT_DEFAULT_PARTITION_ENTRY_ARRAY_SIZE / dev->sector_size; - - /* If the device is too small to have room for data, reject it. */ -- if (data_end <= data_start) -+ if (data_end < data_start) - goto error_free_disk; - - disk->disk_specific = gpt_disk_data = ped_malloc (sizeof (GPTDiskData)); --- -1.9.3 - diff --git a/0024-gpt-when-mklabel-gpt-fails-always-provide-a-diagnost.patch b/0024-gpt-when-mklabel-gpt-fails-always-provide-a-diagnost.patch deleted file mode 100644 index ca4599c..0000000 --- a/0024-gpt-when-mklabel-gpt-fails-always-provide-a-diagnost.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 7ca7f595e4cef589db852394687a6ca0c2925fa7 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 12 Sep 2012 10:48:33 +0200 -Subject: [PATCH 024/131] gpt: when "mklabel gpt" fails, always provide a - diagnostic - -* libparted/labels/gpt.c (gpt_alloc): When rejecting a device because -it is too small, give a diagnostic, as is done in every other failure -path through this function. ---- - libparted/labels/gpt.c | 10 ++++++++-- - 1 file changed, 8 insertions(+), 2 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 564a889..63b30b9 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -504,9 +504,15 @@ gpt_alloc (const PedDevice *dev) - data_end = dev->length - 1 - - GPT_DEFAULT_PARTITION_ENTRY_ARRAY_SIZE / dev->sector_size; - -- /* If the device is too small to have room for data, reject it. */ -+ /* If the device is too small to accommodate GPT headers, reject it. */ - if (data_end < data_start) -- goto error_free_disk; -+ { -+ ped_exception_throw (PED_EXCEPTION_ERROR, -+ PED_EXCEPTION_OK, -+ _("device is so small it cannot even" -+ " accommodate GPT headers")); -+ goto error_free_disk; -+ } - - disk->disk_specific = gpt_disk_data = ped_malloc (sizeof (GPTDiskData)); - if (!disk->disk_specific) --- -1.9.3 - diff --git a/0025-tests-show-that-small-dev-now-evokes-mklabel-gpt-dia.patch b/0025-tests-show-that-small-dev-now-evokes-mklabel-gpt-dia.patch deleted file mode 100644 index 27e851b..0000000 --- a/0025-tests-show-that-small-dev-now-evokes-mklabel-gpt-dia.patch +++ /dev/null @@ -1,82 +0,0 @@ -From 42c1964bdc2311ec142453cf43a8737da81b2f0d Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 12 Sep 2012 10:43:17 +0200 -Subject: [PATCH 025/131] tests: show that small dev now evokes "mklabel gpt" - diagnostic - -* tests/t0203-gpt-create-on-min-sized-device.sh: New test. -* tests/Makefile.am (TESTS): Add it. ---- - tests/Makefile.am | 1 + - tests/t0203-gpt-create-on-min-sized-device.sh | 47 +++++++++++++++++++++++++++ - 2 files changed, 48 insertions(+) - create mode 100644 tests/t0203-gpt-create-on-min-sized-device.sh - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index c97400b..66b9361 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -16,6 +16,7 @@ TESTS = \ - t0202-gpt-pmbr.sh \ - t0203-gpt-tiny-device-abort.sh \ - t0203-gpt-shortened-device-primary-valid.sh \ -+ t0203-gpt-create-on-min-sized-device.sh \ - t0205-gpt-list-clobbers-pmbr.sh \ - t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh \ - t0207-IEC-binary-notation.sh \ -diff --git a/tests/t0203-gpt-create-on-min-sized-device.sh b/tests/t0203-gpt-create-on-min-sized-device.sh -new file mode 100644 -index 0000000..113e191 ---- /dev/null -+++ b/tests/t0203-gpt-create-on-min-sized-device.sh -@@ -0,0 +1,47 @@ -+#!/bin/sh -+# parted 3.1 and prior would exit with no diagnostic when failing -+# to create a GPT partition table on a device that was too small. -+ -+# Copyright (C) 2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+require_512_byte_sector_size_ -+ -+dev=loop-file -+ss=$sector_size_ -+ -+# Create the smallest file that can accommodate a GPT partition table. -+dd if=/dev/null of=$dev bs=$ss seek=67 || framework_failure -+ -+# create a GPT partition table -+parted -s $dev mklabel gpt > out 2>&1 || fail=1 -+# expect no output -+compare /dev/null out || fail=1 -+ -+# Create a file that is 1 sector smaller, and require failure, -+# *with* a diagnostic. -+rm -f $dev -+dd if=/dev/null of=$dev bs=$ss seek=66 || framework_failure -+ -+echo Error: device is so small it cannot even accommodate GPT headers \ -+ > exp || framework_failure -+ -+# Try to create a GPT partition table in too little space. This must fail. -+parted -s $dev mklabel gpt > out 2>&1 && fail=1 -+# There must be a diagnostic. -+compare out exp || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0026-tests-avoid-syntax-check-failure-for-reversed-compar.patch b/0026-tests-avoid-syntax-check-failure-for-reversed-compar.patch deleted file mode 100644 index 27d869e..0000000 --- a/0026-tests-avoid-syntax-check-failure-for-reversed-compar.patch +++ /dev/null @@ -1,27 +0,0 @@ -From bcc6517853c09f979951ab483bd6560d45bf8e3f Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Thu, 20 Sep 2012 20:22:13 +0200 -Subject: [PATCH 026/131] tests: avoid syntax-check failure for reversed - compare args - -* tests/t0203-gpt-create-on-min-sized-device.sh: Reverse args, -so that any diff output (upon failed test) looks sensible. ---- - tests/t0203-gpt-create-on-min-sized-device.sh | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/tests/t0203-gpt-create-on-min-sized-device.sh b/tests/t0203-gpt-create-on-min-sized-device.sh -index 113e191..4cec64c 100644 ---- a/tests/t0203-gpt-create-on-min-sized-device.sh -+++ b/tests/t0203-gpt-create-on-min-sized-device.sh -@@ -42,6 +42,6 @@ echo Error: device is so small it cannot even accommodate GPT headers \ - # Try to create a GPT partition table in too little space. This must fail. - parted -s $dev mklabel gpt > out 2>&1 && fail=1 - # There must be a diagnostic. --compare out exp || fail=1 -+compare exp out || fail=1 - - Exit $fail --- -1.9.3 - diff --git a/0027-mac-don-t-let-larger-partition-table-specified-block.patch b/0027-mac-don-t-let-larger-partition-table-specified-block.patch deleted file mode 100644 index 9149f36..0000000 --- a/0027-mac-don-t-let-larger-partition-table-specified-block.patch +++ /dev/null @@ -1,78 +0,0 @@ -From 6c7932b90a9d078ffaf8ec9482b272c67d75a01d Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 4 Sep 2012 16:42:34 -0700 -Subject: [PATCH 027/131] mac: don't let larger partition-table-specified block - size evoke UB - -For example, in reading a MAC partition table on a 512-byte sector-size -disk, _disk_analyse_block_size could find reason to ask if it's ok to -increase that to e.g., 2048. Upon a positive reply, we would read 2048 -bytes into a 512-byte buffer. - -* libparted/labels/mac.c (mac_read): If needed, reallocate "buf" -to accommodate a new, larger sector size. -* NEWS (Bug fixes): Mention it. ---- - NEWS | 7 +++++++ - libparted/labels/mac.c | 14 +++++++++++++- - 2 files changed, 20 insertions(+), 1 deletion(-) - -diff --git a/NEWS b/NEWS -index f929b99..bab3afb 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,13 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: mac: a MAC partition table could have a block_size larger -+ than the one the kernel told us about. Upon reading that partition -+ table, libparted would ask if it's ok to use the larger block size. -+ If you were to respond in the affirmative, libparted would read the -+ larger number of bytes into a buffer of the shorter length, -+ overrunning it. -+ - libparted: gpt: fix gpt_get_max_supported_partition_count to work - also on little-endian systems. - -diff --git a/libparted/labels/mac.c b/libparted/labels/mac.c -index 1f59a1a..2485187 100644 ---- a/libparted/labels/mac.c -+++ b/libparted/labels/mac.c -@@ -738,13 +738,16 @@ mac_read (PedDisk* disk) - if (!ptt_read_sector (disk->dev, 0, &buf)) - return 0; - -- MacRawDisk *raw_disk = (MacRawDisk *) buf; -+ MacRawDisk *raw_disk = buf; - - if (!_check_signature (raw_disk)) - goto error; - -+ /* Record the original sector size; this function may change it. */ -+ PedSector ss0 = disk->dev->sector_size; - if (!_disk_analyse_block_size (disk, raw_disk)) - goto error; -+ - if (!_disk_analyse_ghost_size (disk)) - goto error; - ghost_size = mac_disk_data->ghost_size; -@@ -759,6 +762,15 @@ mac_read (PedDisk* disk) - mac_disk_data->block_size = raw_disk->block_size; - } - -+ /* If _disk_analyse_block_size has increased the sector_size, -+ reallocate this buffer, so we can still read a sector into it. */ -+ if (ss0 < disk->dev->sector_size) { -+ free (buf); -+ buf = ped_malloc (disk->dev->sector_size); -+ if (buf == NULL) -+ goto error; -+ } -+ - for (num=1; num==1 || num <= last_part_entry_num; num++) { - void *raw_part = buf; - if (!ped_device_read (disk->dev, raw_part, --- -1.9.3 - diff --git a/0028-tests-mac-exercise-the-just-fixed-bug.patch b/0028-tests-mac-exercise-the-just-fixed-bug.patch deleted file mode 100644 index bb7717a..0000000 --- a/0028-tests-mac-exercise-the-just-fixed-bug.patch +++ /dev/null @@ -1,83 +0,0 @@ -From 6499402a18baf22f08084acb289431b731d3afda Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Thu, 20 Sep 2012 20:18:50 +0200 -Subject: [PATCH 028/131] tests: mac: exercise the just-fixed bug - -* tests/t0350-mac-PT-increases-sector-size.sh: New test. -* tests/Makefile.am (TESTS): Add it. ---- - tests/Makefile.am | 1 + - tests/t0350-mac-PT-increases-sector-size.sh | 49 +++++++++++++++++++++++++++++ - 2 files changed, 50 insertions(+) - create mode 100644 tests/t0350-mac-PT-increases-sector-size.sh - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 66b9361..96abecb 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -30,6 +30,7 @@ TESTS = \ - t0280-gpt-corrupt.sh \ - t0300-dos-on-gpt.sh \ - t0301-overwrite-gpt-pmbr.sh \ -+ t0350-mac-PT-increases-sector-size.sh \ - t0400-loop-clobber-infloop.sh \ - t0500-dup-clobber.sh \ - t0501-duplicate.sh \ -diff --git a/tests/t0350-mac-PT-increases-sector-size.sh b/tests/t0350-mac-PT-increases-sector-size.sh -new file mode 100644 -index 0000000..2dbd8cd ---- /dev/null -+++ b/tests/t0350-mac-PT-increases-sector-size.sh -@@ -0,0 +1,49 @@ -+#!/bin/sh -+# With parted-3.1, a MAC partition table that specified a sector size (B) -+# larger than what the kernel told us (SS) would cause parted to read B -+# bytes into a smaller, SS-byte buffer, clobbering heap storage. -+ -+# Copyright (C) 2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+require_512_byte_sector_size_ -+ -+dev=loop-file -+ss=$sector_size_ -+ -+dd if=/dev/null of=$dev bs=$ss seek=2000 || framework_failure -+parted -s $dev mklabel mac > out 2>&1 || fail=1 -+# expect no output -+compare /dev/null out || fail=1 -+ -+# Poke a big-endian 1024 into the 2-byte block_size slot. -+perl -e 'print pack("S>", 1024)'|dd of=$dev bs=1 seek=2 count=2 conv=notrunc \ -+ || fail=1 -+ -+printf 'ignore\ncancel\n' > in || framework_failure -+ -+cat < exp -+BYT; -+FILE:2000s:file:1024:512:unknown::; -+EOF -+ -+parted -m ---pretend-input-tty $dev u s p < in > err 2>&1 || fail=1 -+sed 's, * ,,g;s!^/[^:]*:!FILE:!' err \ -+ | grep -Evi '^(ignore|fix|error|warning)' \ -+ > k && mv k err || fail=1 -+compare exp err || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0029-add-support-for-a-new-Linux-specific-GPT-partition-t.patch b/0029-add-support-for-a-new-Linux-specific-GPT-partition-t.patch deleted file mode 100644 index bfb0480..0000000 --- a/0029-add-support-for-a-new-Linux-specific-GPT-partition-t.patch +++ /dev/null @@ -1,333 +0,0 @@ -From e6536360bd4496cee1f1bf2dfb0b11f6bdbbfd4b Mon Sep 17 00:00:00 2001 -From: "Roderick W. Smith" -Date: Sun, 23 Sep 2012 21:29:10 +0200 -Subject: [PATCH 029/131] add support for a new Linux-specific GPT partition - type code - -* NEWS: Describe the new Linux-specific partition type code -and the new msftres flag that can be used to override this type -code, should it be necessary. -* doc/parted.texi: Describe of the new msftres flag. -* include/parted/disk.in.h [_PedPartitionFlag]: Add -PED_PARTITION_MSFT_DATA. -* libparted/disk.c: Add check for PED_PARTITION_MSFT_DATA, with -return of "msftdata", to ped_partition_flag_get_name() -* libparted/labels/gpt.c (PARTITION_LINUX_DATA_GUID): Define. -[_GPTPartitionData]: New member, "int msftdata". -(_parse_part_entry): Set the msftdata flag if and only if the -PARTITION_BASIC_DATA_GUID type code is in use; -(gpt_partition_new): Use the PARTITION_LINUX_DATA_GUID -type as the default type code -(gpt_partition_set_system): Set the PARTITION_BASIC_DATA_GUID type -code on partitions on which the msftdata flag is set and set -PARTITION_LINUX_DATA_GUID as the type by default. -Clear the msftdata flag in most tests in gpt_partition_set_flag() -(gpt_partition_set_flag): Add test for PED_PARTITION_MSFT_DATA, which -sets msftdata and other flags appropriately -(gpt_partition_get_flag): Add test for the PED_PARTITION_MSFT_DATA -item that returns the status of the msftdata flag -(gpt_partition_is_flag_available): Add test for -PED_PARTITION_MSFT_DATA item to -* tests/t0220-gpt-msftres.sh: Accommodate the fact that now, -partition table listings include "msftdata" for file systems -of type NTFS and FAT*. -For more discussion and justification, see -http://thread.gmane.org/gmane.comp.gnu.parted.bugs/10456 ---- - NEWS | 19 +++++++++++++++++++ - doc/parted.texi | 16 +++++++++++++++- - include/parted/disk.in.h | 5 +++-- - libparted/disk.c | 2 ++ - libparted/labels/gpt.c | 45 +++++++++++++++++++++++++++++++++++++++++++-- - tests/t0220-gpt-msftres.sh | 3 ++- - 6 files changed, 84 insertions(+), 6 deletions(-) - -diff --git a/NEWS b/NEWS -index bab3afb..4c4716d 100644 ---- a/NEWS -+++ b/NEWS -@@ -17,6 +17,25 @@ GNU parted NEWS -*- outline -*- - libparted: treat a disk with no pMBR as an msdos-labeled disk - even when it has valid GPT headers. - -+** Changes in behavior -+ -+ Added new Linux-specific partition GUID type code -+ (0FC63DAF-8483-4772-8E79-3D69D8477DE4) for Linux filesystem data on GPT -+ disks. This type code is now assigned as the default partition type code -+ for new partitions holding Linux filesystems. -+ -+ Added new "msftdata" flag to identify partitions holding NTFS or FAT -+ filesystems on GPT disks. This flag corresponds to a GPT type code of -+ EBD0A0A2-B9E5-4433-87C0-68B6B72699C7 ("Microsoft Basic Data"). Since -+ Linux filesystem partitions formerly used this type code, this flag may -+ optionally be set on Linux partitions to make the partition table type -+ codes match former configurations in case the new Linux filesystem type -+ code causes problems with some utility. Note that this flag cannot be -+ removed from NTFS or FAT partitions within parted except by setting a -+ competing flag, such as "boot" (which sets the type code used by EFI -+ System partitions) or "msftres" (which sets the "Microsoft Reserved" type -+ code). -+ - - * Noteworthy changes in release 3.1 (2012-03-02) [stable] - -diff --git a/doc/parted.texi b/doc/parted.texi -index 1601151..b8db19d 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -793,6 +793,20 @@ on a partition that partition must be bootable. - For PC98 disk labels, all ext2 partitions must be bootable (this is - enforced by Parted). - -+@item msftdata -+(GPT) - This flag identifies partitions that contain Microsoft filesystems -+(NTFS or FAT). It may optionally be set on Linux filesystems to mimic the -+type of configuration created by parted 3.0 and earlier, in which a -+separate Linux filesystem type code was not available on GPT disks. This -+flag can only be removed within parted by replacing it with a competing -+flag, such as boot or msftres. -+ -+@item msftres -+(GPT) - This flag identifies a "Microsoft Reserved" partition, which is -+used by Windows on GPT disks. Note that this flag should not normally be -+set on Windows filesystem partitions (those that contain NTFS or FAT -+filesystems). -+ - @item lba - (MS-DOS) - this flag can be enabled to tell MS DOS, MS Windows 9x and - MS Windows ME based operating systems to use Linear (LBA) mode. -@@ -907,7 +921,7 @@ which case this unit apply instead of the default unit for this - particular number, but CHS and cylinder units are not supported as - a suffix. If no suffix is given, then the default unit is assumed. - Parted will compute sensible ranges for the locations you specify --(e.g. a range of +/- 500 MB when you specify the location in ``G'', -+(e.g., a range of +/- 500 MB when you specify the location in ``G'', - and a range of +/- 500 KB when you specify the location in ``M'') - and will select the nearest location in this range from the one you - wrote that satisfies constraints from both the operation, the -diff --git a/include/parted/disk.in.h b/include/parted/disk.in.h -index 9734edd..a34e11e 100644 ---- a/include/parted/disk.in.h -+++ b/include/parted/disk.in.h -@@ -72,10 +72,11 @@ enum _PedPartitionFlag { - PED_PARTITION_BIOS_GRUB=12, - PED_PARTITION_APPLE_TV_RECOVERY=13, - PED_PARTITION_DIAG=14, -- PED_PARTITION_LEGACY_BOOT=15 -+ PED_PARTITION_LEGACY_BOOT=15, -+ PED_PARTITION_MSFT_DATA=16 - }; - #define PED_PARTITION_FIRST_FLAG PED_PARTITION_BOOT --#define PED_PARTITION_LAST_FLAG PED_PARTITION_LEGACY_BOOT -+#define PED_PARTITION_LAST_FLAG PED_PARTITION_MSFT_DATA - - enum _PedDiskTypeFeature { - PED_DISK_TYPE_EXTENDED=1, /**< supports extended partitions */ -diff --git a/libparted/disk.c b/libparted/disk.c -index f9b5fd2..c4b1a01 100644 ---- a/libparted/disk.c -+++ b/libparted/disk.c -@@ -2433,6 +2433,8 @@ ped_partition_flag_get_name (PedPartitionFlag flag) - return N_("prep"); - case PED_PARTITION_MSFT_RESERVED: - return N_("msftres"); -+ case PED_PARTITION_MSFT_DATA: -+ return N_("msftdata"); - case PED_PARTITION_APPLE_TV_RECOVERY: - return N_("atvrecv"); - case PED_PARTITION_DIAG: -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 63b30b9..490de70 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -122,6 +122,10 @@ typedef struct - ((efi_guid_t) { PED_CPU_TO_LE32 (0x0657fd6d), PED_CPU_TO_LE16 (0xa4ab), \ - PED_CPU_TO_LE16 (0x43c4), 0x84, 0xe5, \ - { 0x09, 0x33, 0xc8, 0x4b, 0x4f, 0x4f }}) -+#define PARTITION_LINUX_DATA_GUID \ -+ ((efi_guid_t) { PED_CPU_TO_LE32 (0x0FC63DAF), PED_CPU_TO_LE16 (0x8483), \ -+ PED_CPU_TO_LE16 (0x4772), 0x8E, 0x79, \ -+ { 0x3D, 0x69, 0xD8, 0x47, 0x7D, 0xE4 }}) - #define PARTITION_LVM_GUID \ - ((efi_guid_t) { PED_CPU_TO_LE32 (0xe6d6d379), PED_CPU_TO_LE16 (0xf507), \ - PED_CPU_TO_LE16 (0x44c2), 0xa2, 0x3c, \ -@@ -280,6 +284,7 @@ typedef struct _GPTPartitionData - int hp_service; - int hidden; - int msftres; -+ int msftdata; - int atvrecv; - int msftrecv; - int legacy_boot; -@@ -788,6 +793,7 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - gpt_part_data->lvm = gpt_part_data->raid - = gpt_part_data->boot = gpt_part_data->hp_service - = gpt_part_data->hidden = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->legacy_boot - = gpt_part_data->bios_grub = gpt_part_data->atvrecv = 0; -@@ -809,6 +815,8 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - gpt_part_data->hp_service = 1; - else if (!guid_cmp (gpt_part_data->type, PARTITION_MSFT_RESERVED_GUID)) - gpt_part_data->msftres = 1; -+ else if (!guid_cmp (gpt_part_data->type, PARTITION_BASIC_DATA_GUID)) -+ gpt_part_data->msftdata = 1; - else if (!guid_cmp (gpt_part_data->type, PARTITION_MSFT_RECOVERY)) - gpt_part_data->msftrecv = 1; - else if (!guid_cmp (gpt_part_data->type, PARTITION_APPLE_TV_RECOVERY_GUID)) -@@ -1318,7 +1326,7 @@ gpt_partition_new (const PedDisk *disk, - if (!gpt_part_data) - goto error_free_part; - -- gpt_part_data->type = PARTITION_BASIC_DATA_GUID; -+ gpt_part_data->type = PARTITION_LINUX_DATA_GUID; - gpt_part_data->lvm = 0; - gpt_part_data->raid = 0; - gpt_part_data->boot = 0; -@@ -1326,6 +1334,7 @@ gpt_partition_new (const PedDisk *disk, - gpt_part_data->hp_service = 0; - gpt_part_data->hidden = 0; - gpt_part_data->msftres = 0; -+ gpt_part_data->msftdata = 0; - gpt_part_data->msftrecv = 0; - gpt_part_data->atvrecv = 0; - gpt_part_data->legacy_boot = 0; -@@ -1422,6 +1431,11 @@ gpt_partition_set_system (PedPartition *part, - gpt_part_data->type = PARTITION_MSFT_RESERVED_GUID; - return 1; - } -+ if (gpt_part_data->msftdata) -+ { -+ gpt_part_data->type = PARTITION_BASIC_DATA_GUID; -+ return 1; -+ } - if (gpt_part_data->msftrecv) - { - gpt_part_data->type = PARTITION_MSFT_RECOVERY; -@@ -1453,7 +1467,7 @@ gpt_partition_set_system (PedPartition *part, - } - } - -- gpt_part_data->type = PARTITION_BASIC_DATA_GUID; -+ gpt_part_data->type = PARTITION_LINUX_DATA_GUID; - return 1; - } - -@@ -1571,6 +1585,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->bios_grub - = gpt_part_data->hp_service - = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); -@@ -1582,6 +1597,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->boot - = gpt_part_data->hp_service - = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); -@@ -1593,6 +1609,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->bios_grub - = gpt_part_data->hp_service - = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); -@@ -1604,6 +1621,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->bios_grub - = gpt_part_data->hp_service - = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); -@@ -1615,6 +1633,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->lvm - = gpt_part_data->bios_grub - = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); -@@ -1626,8 +1645,25 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->lvm - = gpt_part_data->bios_grub - = gpt_part_data->hp_service -+ = gpt_part_data->msftdata -+ = gpt_part_data->msftrecv -+ = gpt_part_data->atvrecv = 0; -+ return gpt_partition_set_system (part, part->fs_type); -+ case PED_PARTITION_MSFT_DATA: -+ gpt_part_data->msftres = state; -+ if (state) { -+ gpt_part_data->boot -+ = gpt_part_data->raid -+ = gpt_part_data->lvm -+ = gpt_part_data->bios_grub -+ = gpt_part_data->hp_service -+ = gpt_part_data->msftres - = gpt_part_data->msftrecv - = gpt_part_data->atvrecv = 0; -+ gpt_part_data->msftdata = 1; -+ } else { -+ gpt_part_data->msftdata = 0; -+ } - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_DIAG: - gpt_part_data->msftrecv = state; -@@ -1637,6 +1673,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->lvm - = gpt_part_data->bios_grub - = gpt_part_data->hp_service -+ = gpt_part_data->msftdata - = gpt_part_data->msftres - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); -@@ -1649,6 +1686,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->bios_grub - = gpt_part_data->hp_service - = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_HIDDEN: -@@ -1687,6 +1725,8 @@ gpt_partition_get_flag (const PedPartition *part, PedPartitionFlag flag) - return gpt_part_data->hp_service; - case PED_PARTITION_MSFT_RESERVED: - return gpt_part_data->msftres; -+ case PED_PARTITION_MSFT_DATA: -+ return gpt_part_data->msftdata; - case PED_PARTITION_DIAG: - return gpt_part_data->msftrecv; - case PED_PARTITION_APPLE_TV_RECOVERY: -@@ -1716,6 +1756,7 @@ gpt_partition_is_flag_available (const PedPartition *part, - case PED_PARTITION_BIOS_GRUB: - case PED_PARTITION_HPSERVICE: - case PED_PARTITION_MSFT_RESERVED: -+ case PED_PARTITION_MSFT_DATA: - case PED_PARTITION_DIAG: - case PED_PARTITION_APPLE_TV_RECOVERY: - case PED_PARTITION_HIDDEN: -diff --git a/tests/t0220-gpt-msftres.sh b/tests/t0220-gpt-msftres.sh -index d522aec..bd14c84 100755 ---- a/tests/t0220-gpt-msftres.sh -+++ b/tests/t0220-gpt-msftres.sh -@@ -56,7 +56,8 @@ printf "BYT;\n$dev:${n_sectors}s:file:$ss:$ss:gpt::;\n" > exp - i=1 - for type in $fs_types; do - end=$(expr $start + $part_size - 1) -- echo "$i:${start}s:${end}s:${part_size}s::$type:;" >> exp || fail=1 -+ case $type in fat*|NTFS) flag=msftdata;; *) flag=;; esac -+ echo "$i:${start}s:${end}s:${part_size}s::$type:$flag;" >> exp || fail=1 - parted -s $dev mkpart p-name $type ${start}s ${end}s > err 2>&1 || fail=1 - compare /dev/null err || fail=1 - parted -s $dev name $i $type > err 2>&1 || fail=1 --- -1.9.3 - diff --git a/0030-tests-clean-up-tests.patch b/0030-tests-clean-up-tests.patch deleted file mode 100644 index 61682f5..0000000 --- a/0030-tests-clean-up-tests.patch +++ /dev/null @@ -1,341 +0,0 @@ -From c987c73cbe773dfa3b14b911ffc243137195bbb3 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sat, 29 Sep 2012 12:10:35 +0200 -Subject: [PATCH 030/131] tests: clean up tests - -Use warn_ and $ME_ in place of warn and $ME; remove definitions of -the latter two. Remove unused code. -* tests/lvm-utils.sh: Remove file. All functions were either unused -or duplicated/better in t-lvm.sh. -* tests/Makefile.am (EXTRA_DIST): Remove it. -* tests/t-local.sh (scsi_debug_setup_): Use echo 1>&2, not warn_, to -emit to log file only, not console. The diagnostic it emitted (in -verbose mode) was more "informational" than a warning. -* tests/t9030-align-check.sh: Use warn_, not warn. -* tests/t-lvm.sh: Likewise, and use fail_, not error (undefined!). -* tests/t-lib-helpers.sh (device_mapper_required_): Use t-lvm.sh -and an explicit lvm_init_root_dir_ in place of lvm-utils.sh. ---- - tests/Makefile.am | 2 +- - tests/lvm-utils.sh | 208 --------------------------------------------- - tests/t-lib-helpers.sh | 4 +- - tests/t-local.sh | 2 +- - tests/t-lvm.sh | 11 +-- - tests/t9030-align-check.sh | 3 +- - 6 files changed, 10 insertions(+), 220 deletions(-) - delete mode 100644 tests/lvm-utils.sh - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 96abecb..80d5525 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -74,7 +74,7 @@ TESTS = \ - t9050-partition-table-types.sh - - EXTRA_DIST = \ -- $(TESTS) lvm-utils.sh t-local.sh t-lvm.sh \ -+ $(TESTS) t-local.sh t-lvm.sh \ - init.cfg init.sh t-lib-helpers.sh gpt-header-munge - - check_PROGRAMS = print-align print-max dup-clobber duplicate fs-resize -diff --git a/tests/lvm-utils.sh b/tests/lvm-utils.sh -deleted file mode 100644 -index 456d265..0000000 ---- a/tests/lvm-utils.sh -+++ /dev/null -@@ -1,208 +0,0 @@ --# Put lvm-related utilities here. --# This file is sourced from test infrastructure. -- --# Copyright (C) 2007-2010 Red Hat, Inc. All rights reserved. --# --# This copyrighted material is made available to anyone wishing to use, --# modify, copy, or redistribute it subject to the terms and conditions --# of the GNU General Public License v.2. --# --# You should have received a copy of the GNU General Public License --# along with this program; if not, write to the Free Software Foundation, --# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -- --export LVM_SUPPRESS_FD_WARNINGS=1 -- --ME=$(basename "$0") --warn() { echo >&2 "$ME: $@"; } -- --unsafe_losetup_() --{ -- f=$1 -- -- test -n "$G_dev_" \ -- || fail_ "Internal error: unsafe_losetup_ called before init_root_dir_" -- -- # Iterate through $G_dev_/loop{,/}{0,1,2,3,4,5,6,7,8,9} -- for slash in '' /; do -- for i in 0 1 2 3 4 5 6 7 8 9; do -- dev=$G_dev_/loop$slash$i -- losetup $dev > /dev/null 2>&1 && continue; -- losetup "$dev" "$f" > /dev/null && { echo "$dev"; return 0; } -- break -- done -- done -- -- return 1 --} -- --loop_setup_() --{ -- file=$1 -- dd if=/dev/zero of="$file" bs=1M count=1 seek=1000 > /dev/null 2>&1 \ -- || { warn "loop_setup_ failed: Unable to create tmp file $file"; return 1; } -- -- # NOTE: this requires a new enough version of losetup -- dev=$(unsafe_losetup_ "$file") \ -- || { warn "loop_setup_ failed: Unable to create loopback device"; return 1; } -- -- echo "$dev" -- return 0; --} -- --compare_two_fields_() --{ -- local cmd1=$1; -- local obj1=$2; -- local field1=$3; -- local cmd2=$4; -- local obj2=$5; -- local field2=$6; -- local val1; -- local val2; -- -- val1=$($cmd1 --noheadings -o $field1 $obj1) -- val2=$($cmd2 --noheadings -o $field2 $obj2) --if test "$verbose" = "t" --then -- echo "compare_two_fields_ $obj1($field1): $val1 $obj2($field2): $val2" --fi -- test $val1 = $val2 --} -- --compare_vg_field_() --{ -- local vg1=$1; -- local vg2=$2; -- local field=$3; -- local val1; -- local val2; -- -- val1=$(vgs --noheadings -o $field $vg1) -- val2=$(vgs --noheadings -o $field $vg2) --if test "$verbose" = "t" --then -- echo "compare_vg_field_ VG1: $val1 VG2: $val2" --fi -- test $val1 = $val2 --} -- --check_vg_field_() --{ -- local vg=$1; -- local field=$2; -- local expected=$3; -- local actual; -- -- actual=$(vgs --noheadings -o $field $vg) --if test "$verbose" = "t" --then -- echo "check_vg_field_ VG=$vg, field=$field, actual=$actual, expected=$expected" --fi -- test $actual = $expected --} -- --check_pv_field_() --{ -- local pv=$1; -- local field=$2; -- local expected=$3; -- local actual; -- -- actual=$(pvs --noheadings -o $field $pv) --if test "$verbose" = "t" --then -- echo "check_pv_field_ PV=$pv, field=$field, actual=$actual, expected=$expected" --fi -- test $actual = $expected --} -- --check_lv_field_() --{ -- local lv=$1; -- local field=$2; -- local expected=$3; -- local actual; -- -- actual=$(lvs --noheadings -o $field $lv) --if test "$verbose" = "t" --then -- echo "check_lv_field_ LV=$lv, field=$field, actual=$actual, expected=$expected" --fi -- test $actual = $expected --} -- --vg_validate_pvlv_counts_() --{ -- local local_vg=$1 -- local num_pvs=$2 -- local num_lvs=$3 -- local num_snaps=$4 -- -- check_vg_field_ $local_vg pv_count $num_pvs && -- check_vg_field_ $local_vg lv_count $num_lvs && -- check_vg_field_ $local_vg snap_count $num_snaps --} -- --dmsetup_has_dm_devdir_support_() --{ -- # Detect support for the envvar. If it's supported, the -- # following command will fail with the expected diagnostic. -- out=$(DM_DEV_DIR=j dmsetup version 2>&1) -- test "$?:$out" = "1:Invalid DM_DEV_DIR envvar value." || -- test "$?:$out" = "1:Invalid DM_DEV_DIR environment variable value." --} -- --# set up private /dev and /etc --init_root_dir_() --{ -- test -n "$test_dir_" \ -- || fail_ "Internal error: called init_root_dir_ before" \ -- "defining \$test_dir_" -- -- # Define these two globals. -- G_root_=$test_dir_/root -- G_dev_=$G_root_/dev -- -- export LVM_SYSTEM_DIR=$G_root_/etc -- export DM_DEV_DIR=$G_dev_ -- -- # Only the first caller does anything. -- mkdir -p $G_root_/etc $G_dev_ $G_dev_/mapper $G_root_/lib -- for i in 0 1 2 3 4 5 6 7; do -- mknod $G_root_/dev/loop$i b 7 $i -- done -- for i in $abs_top_builddir/dmeventd/mirror/*.so $abs_top_builddir/dmeventd/snapshot/*.so -- do -- # NOTE: This check is necessary because the loop above will give us the value -- # "$abs_top_builddir/dmeventd/mirror/*.so" if no files ending in 'so' exist. -- # This is the best way I could quickly determine to skip over this bogus value. -- if [ -f $i ]; then -- echo Setting up symlink from $i to $G_root_/lib -- ln -s $i $G_root_/lib -- fi -- done -- cat > $G_root_/etc/lvm.conf <<-EOF -- devices { -- dir = "$G_dev_" -- scan = "$G_dev_" -- filter = [ "a/loop/", "a/mirror/", "a/mapper/", "r/.*/" ] -- cache_dir = "$G_root_/etc" -- sysfs_scan = 0 -- } -- log { -- verbose = $verboselevel -- syslog = 0 -- indent = 1 -- } -- backup { -- backup = 0 -- archive = 0 -- } -- global { -- library_dir = "$G_root_/lib" -- } --EOF --} -- --init_root_dir_ -diff --git a/tests/t-lib-helpers.sh b/tests/t-lib-helpers.sh -index 4b3c122..6721003 100644 ---- a/tests/t-lib-helpers.sh -+++ b/tests/t-lib-helpers.sh -@@ -395,6 +395,6 @@ wait_for_dev_to_disappear_() - - device_mapper_required_() - { -- . "$abs_top_srcdir/tests/lvm-utils.sh" \ -- || fail_ "device mapper setup failed" -+ . "$abs_top_srcdir/tests/t-lvm.sh" -+ lvm_init_root_dir_ || fail_ "device mapper setup failed" - } -diff --git a/tests/t-local.sh b/tests/t-local.sh -index dde1b8d..b40a5a0 100644 ---- a/tests/t-local.sh -+++ b/tests/t-local.sh -@@ -100,7 +100,7 @@ scsi_debug_setup_() - modprobe scsi_debug "$@" || { rm -f stamp; return 1; } - scsi_debug_modprobe_succeeded_=1 - test "$VERBOSE" = yes \ -- && warn_ $ME_ modprobe scsi_debug succeeded -+ && echo $ME_ modprobe scsi_debug succeeded 1>&2 - - # Wait up to 2s (via .1s increments) for the list of devices to change. - # Sleeping for a fraction of a second requires GNU sleep, so fall -diff --git a/tests/t-lvm.sh b/tests/t-lvm.sh -index b08f934..9cee155 100644 ---- a/tests/t-lvm.sh -+++ b/tests/t-lvm.sh -@@ -1,7 +1,7 @@ - # Put lvm-related utilities here. - # This file is sourced from test infrastructure. - --# Copyright (C) 2007, 2008, 2010 Red Hat, Inc. All rights reserved. -+# Copyright (C) 2007-2012 Red Hat, Inc. All rights reserved. - # - # This copyrighted material is made available to anyone wishing to use, - # modify, copy, or redistribute it subject to the terms and conditions -@@ -13,15 +13,12 @@ - - export LVM_SUPPRESS_FD_WARNINGS=1 - --ME=$(basename "$0") --warn() { echo >&2 "$ME: $@"; } -- - unsafe_losetup_() - { - f=$1 - - test -n "$G_dev_" \ -- || error "Internal error: unsafe_losetup_ called before init_root_dir_" -+ || fail_ "Internal error: unsafe_losetup_ called before init_root_dir_" - - # Iterate through $G_dev_/loop{,/}{0,1,2,3,4,5,6,7,8,9} - for slash in '' /; do -@@ -40,11 +37,11 @@ loop_setup_() - { - file=$1 - dd if=/dev/zero of="$file" bs=1M count=1 seek=1000 > /dev/null 2>&1 \ -- || { warn "loop_setup_ failed: Unable to create tmp file $file"; return 1; } -+ || { warn_ "loop_setup_ failed: Unable to create tmp file $file"; return 1; } - - # NOTE: this requires a new enough version of losetup - dev=$(unsafe_losetup_ "$file" 2>/dev/null) \ -- || { warn "loop_setup_ failed: Unable to create loopback device"; return 1; } -+ || { warn_ "loop_setup_ failed: Unable to create loopback device"; return 1; } - - echo "$dev" - return 0; -diff --git a/tests/t9030-align-check.sh b/tests/t9030-align-check.sh -index b3618a7..f0830f0 100644 ---- a/tests/t9030-align-check.sh -+++ b/tests/t9030-align-check.sh -@@ -49,7 +49,8 @@ while :; do - test $i = 70 && break - - # Wait up to 10s for the partition file to disappear. -- wait_for_dev_to_disappear_ $p1 10 || { fail=1; warn $p1 failed to disappear; } -+ wait_for_dev_to_disappear_ $p1 10 \ -+ || { fail=1; warn_ $ME_ $p1 failed to disappear; } - done - - Exit $fail --- -1.9.3 - diff --git a/0031-doc-libparted-disk.c-correct-doxygen-comment-typo.patch b/0031-doc-libparted-disk.c-correct-doxygen-comment-typo.patch deleted file mode 100644 index 5234c40..0000000 --- a/0031-doc-libparted-disk.c-correct-doxygen-comment-typo.patch +++ /dev/null @@ -1,27 +0,0 @@ -From fb1faafaae67c328a34117573a71d1f02ef9f6fe Mon Sep 17 00:00:00 2001 -From: Bob Beers -Date: Thu, 4 Oct 2012 06:00:25 +0200 -Subject: [PATCH 031/131] doc: libparted/disk.c: correct doxygen comment typo - -* libparted/disk.c: s/PedPartition/PedDisk/ -Copyright-paperwork-exempt: yes ---- - libparted/disk.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/libparted/disk.c b/libparted/disk.c -index c4b1a01..d283674 100644 ---- a/libparted/disk.c -+++ b/libparted/disk.c -@@ -1968,7 +1968,7 @@ _check_partition (PedDisk* disk, PedPartition* part) - } - - /** -- * Adds PedPartition \p part to PedPartition \p disk. -+ * Adds PedPartition \p part to PedDisk \p disk. - * - * \warning The partition's geometry may be changed, subject to \p constraint. - * You could set \p constraint to ped_constraint_exact(&part->geom), --- -1.9.3 - diff --git a/0032-tests-stop-using-private-dev-directory-for-losetup.patch b/0032-tests-stop-using-private-dev-directory-for-losetup.patch deleted file mode 100644 index fa17a33..0000000 --- a/0032-tests-stop-using-private-dev-directory-for-losetup.patch +++ /dev/null @@ -1,47 +0,0 @@ -From 478e472bf9f1c76b66a35ea75b45110152e5207d Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sat, 6 Oct 2012 11:11:32 +0200 -Subject: [PATCH 032/131] tests: stop using private "dev" directory for losetup - -Something about Fedora 17's losetup changed so that using a private -dev directory no longer worked. Now, simply use /dev/ directly. -* tests/t-lvm.sh: Don't use $G_dev_. Not needed, and actually -caused the t6000-dm root-only test to fail on Fedora 17. -Also, redirect less to stderr: that helps diagnose failure. ---- - tests/t-lvm.sh | 7 +++---- - 1 file changed, 3 insertions(+), 4 deletions(-) - -diff --git a/tests/t-lvm.sh b/tests/t-lvm.sh -index 9cee155..cf1b8b8 100644 ---- a/tests/t-lvm.sh -+++ b/tests/t-lvm.sh -@@ -17,14 +17,13 @@ unsafe_losetup_() - { - f=$1 - -- test -n "$G_dev_" \ -- || fail_ "Internal error: unsafe_losetup_ called before init_root_dir_" -+ G_dev_=/dev - - # Iterate through $G_dev_/loop{,/}{0,1,2,3,4,5,6,7,8,9} - for slash in '' /; do - for i in 0 1 2 3 4 5 6 7 8 9; do - dev=$G_dev_/loop$slash$i -- losetup $dev > /dev/null 2>&1 && continue; -+ losetup $dev 1>&2 && continue; - losetup "$dev" "$f" > /dev/null && { echo "$dev"; return 0; } - break - done -@@ -40,7 +39,7 @@ loop_setup_() - || { warn_ "loop_setup_ failed: Unable to create tmp file $file"; return 1; } - - # NOTE: this requires a new enough version of losetup -- dev=$(unsafe_losetup_ "$file" 2>/dev/null) \ -+ dev=$(unsafe_losetup_ "$file") \ - || { warn_ "loop_setup_ failed: Unable to create loopback device"; return 1; } - - echo "$dev" --- -1.9.3 - diff --git a/0033-maint-fix-an-error-in-the-preceding-commit-log.patch b/0033-maint-fix-an-error-in-the-preceding-commit-log.patch deleted file mode 100644 index 0c223f3..0000000 --- a/0033-maint-fix-an-error-in-the-preceding-commit-log.patch +++ /dev/null @@ -1,59 +0,0 @@ -From 718ac7342412aa7f32aaf3e9f379beb84883406e Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sat, 6 Oct 2012 15:09:56 +0200 -Subject: [PATCH 033/131] maint: fix an error in the preceding commit log - -Stefano Lattarini noticed an error in the log for -commit v3.1-32-g478e472. Arrange for that error -to be fixed in the generated ChangeLog file. -* build-aux/git-log-fix: New file. -* Makefile.am (gen-ChangeLog): Adjust rule to use it. ---- - .gitignore | 3 ++- - Makefile.am | 1 + - build-aux/git-log-fix | 7 +++++++ - 3 files changed, 10 insertions(+), 1 deletion(-) - create mode 100644 build-aux/git-log-fix - -diff --git a/.gitignore b/.gitignore -index 054d9ea..5bb95d4 100644 ---- a/.gitignore -+++ b/.gitignore -@@ -32,7 +32,8 @@ Makefile.in - TAGS - aclocal.m4 - autom4te.cache --build-aux -+/build-aux/* -+!/build-aux/git-log-fix - config.cache - config.h - config.hin -diff --git a/Makefile.am b/Makefile.am -index 5e52a42..686b61c 100644 ---- a/Makefile.am -+++ b/Makefile.am -@@ -107,6 +107,7 @@ gen_start_date = 2000-01-01 - gen-ChangeLog: - if test -d .git; then \ - $(top_srcdir)/build-aux/gitlog-to-changelog \ -+ --amend=$(srcdir)/build-aux/git-log-fix \ - --since=$(gen_start_date) > $(distdir)/cl-t; \ - rm -f $(distdir)/ChangeLog; \ - mv $(distdir)/cl-t $(distdir)/ChangeLog; \ -diff --git a/build-aux/git-log-fix b/build-aux/git-log-fix -new file mode 100644 -index 0000000..e2a68ee ---- /dev/null -+++ b/build-aux/git-log-fix -@@ -0,0 +1,7 @@ -+# This file is expected to be used via gitlog-to-changelog's --amend=FILE -+# option. It specifies what changes to make to each given SHA1's commit -+# log and metadata, using Perl-eval'able expressions. -+ -+478e472bf9f1c76b66a35ea75b45110152e5207d -+# Fix the log message: -+s,stderr,/dev/null, --- -1.9.3 - diff --git a/0034-tests-improve-test-for-partitionable-loop-devices.patch b/0034-tests-improve-test-for-partitionable-loop-devices.patch deleted file mode 100644 index 6b7220a..0000000 --- a/0034-tests-improve-test-for-partitionable-loop-devices.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 5fc054beb415344a0ce44c19e554937c9158d08e Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Tue, 9 Oct 2012 14:02:15 +0200 -Subject: [PATCH 034/131] tests: improve test for partitionable loop devices - -* tests/init.cfg (require_partitionable_loop_device_): Skip -when cat fails. ---- - tests/init.cfg | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) - -diff --git a/tests/init.cfg b/tests/init.cfg -index 24b10bc..dc8b2bc 100644 ---- a/tests/init.cfg -+++ b/tests/init.cfg -@@ -120,8 +120,9 @@ require_erasable_() - # At least Fedora 16 (kernel 3.1.6-1.fc16.x86_64) fails this test. - require_partitionable_loop_device_() - { -- case $(cat /sys/devices/virtual/block/$(basename $1)/ext_range) in -- 0|1) skip_ your system does not support loop partitioning;; -+ local f=/sys/devices/virtual/block/$(basename $1)/ext_range -+ case $(cat "$f") in -+ ''|0|1) skip_ your system is not configured to partition loop devices;; - esac - } - --- -1.9.3 - diff --git a/0035-tests-t8001-do-not-rely-on-modprobe-loop.patch b/0035-tests-t8001-do-not-rely-on-modprobe-loop.patch deleted file mode 100644 index 7da713f..0000000 --- a/0035-tests-t8001-do-not-rely-on-modprobe-loop.patch +++ /dev/null @@ -1,58 +0,0 @@ -From 569e59d08fe2ec5e836536371e0a974a58e83166 Mon Sep 17 00:00:00 2001 -From: Gilles Espinasse -Date: Sun, 7 Oct 2012 15:40:23 +0200 -Subject: [PATCH 035/131] tests: t8001: do not rely on "modprobe loop" - -Remove 'rmmod loop' and 'modprobe loop max_part=7' commands. -The latter command may fail after the first command has run, -leaving the machine with no loop support. - -This happens on my chroot, because: -- rmmod does not depend on the availability of the loop module, -- modprobe fails, since the kernel compiled inside the chroot - is different from the running kernel. - -Instead, rely on t-lvm loop_setup_ to load the loop module, if required. ---- - tests/t8001-loop-blkpg.sh | 12 +++--------- - 1 file changed, 3 insertions(+), 9 deletions(-) - -diff --git a/tests/t8001-loop-blkpg.sh b/tests/t8001-loop-blkpg.sh -index deef18b..9afde4a 100755 ---- a/tests/t8001-loop-blkpg.sh -+++ b/tests/t8001-loop-blkpg.sh -@@ -20,6 +20,7 @@ - - require_root_ - require_udevadm_settle_ -+lvm_init_root_dir_ - - cleanup_fn_() - { -@@ -27,21 +28,14 @@ cleanup_fn_() - && { udevadm settle --timeout=3; losetup -d "$loopdev"; } - } - --# If the loop module is loaded, unload it first --if lsmod | grep '^loop[[:space:]]'; then -- rmmod loop || fail=1 --fi -- --# Insert loop module with max_part > 1 --modprobe loop max_part=7 || fail=1 -- - # Create backing file - dd if=/dev/zero of=backing_file bs=1M count=4 >/dev/null 2>&1 || fail=1 - - # Set up loop device on top of backing file --loopdev=$(losetup -f --show backing_file) -+loopdev=$(loop_setup_ backing_file) - test -z "$loopdev" && fail=1 - -+# Skip this test if loop devices are not partitionable. - require_partitionable_loop_device_ $loopdev - - # Expect this to succeed --- -1.9.3 - diff --git a/0036-build-do-not-rely-on-automake-s-AM_TESTS_ENVIRONMENT.patch b/0036-build-do-not-rely-on-automake-s-AM_TESTS_ENVIRONMENT.patch deleted file mode 100644 index ae95472..0000000 --- a/0036-build-do-not-rely-on-automake-s-AM_TESTS_ENVIRONMENT.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 319e7cd590ae16460cfecb70715bf41ceec81d1e Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Tue, 9 Oct 2012 15:40:33 +0200 -Subject: [PATCH 036/131] build: do not rely on automake's AM_TESTS_ENVIRONMENT - -* tests/Makefile.am (TESTS_ENVIRONMENT): Rename from -AM_TESTS_ENVIRONMENT, since it is not honored in automake-1.11.3 -after all. This reverts commit v3.1-14-g2bd66d7. For now, I'll -leave the following commit that made bootstrap.conf require 1.11.2. -Prompted by a report of test failure from Phillip Susi. ---- - tests/Makefile.am | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 80d5525..cdc1c4b 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -98,7 +98,7 @@ sep = $(PATH_SEPARATOR) - # variables that can perturb tests are unset or set to expected values. - # The rest are envvar settings that propagate build-related Makefile - # variables to test scripts. --AM_TESTS_ENVIRONMENT = \ -+TESTS_ENVIRONMENT = \ - tmp__=$$TMPDIR; test -d "$$tmp__" || tmp__=.; \ - TMPDIR=$$tmp__; export TMPDIR; \ - export \ --- -1.9.3 - diff --git a/0037-build-.gitignore-ignore-tests-fs-resize.patch b/0037-build-.gitignore-ignore-tests-fs-resize.patch deleted file mode 100644 index 25ff57f..0000000 --- a/0037-build-.gitignore-ignore-tests-fs-resize.patch +++ /dev/null @@ -1,24 +0,0 @@ -From 6a535214131b25b0f90dfff618ef6cf8083bb390 Mon Sep 17 00:00:00 2001 -From: Petr Uzel -Date: Mon, 15 Oct 2012 10:31:50 +0200 -Subject: [PATCH 037/131] build: .gitignore: ignore tests/fs-resize - ---- - .gitignore | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/.gitignore b/.gitignore -index 5bb95d4..c2ccd4b 100644 ---- a/.gitignore -+++ b/.gitignore -@@ -76,6 +76,7 @@ stamp-h1 - tags - tests/dup-clobber - tests/duplicate -+tests/fs-resize - tests/help-version.log - tests/old-init.sh - tests/print-align --- -1.9.3 - diff --git a/0038-partprobe-remove-no-update-long-option.patch b/0038-partprobe-remove-no-update-long-option.patch deleted file mode 100644 index c8984b7..0000000 --- a/0038-partprobe-remove-no-update-long-option.patch +++ /dev/null @@ -1,28 +0,0 @@ -From baa2ebd111d4f8df66254bc94ee79aeaae2a3f3e Mon Sep 17 00:00:00 2001 -From: Petr Uzel -Date: Mon, 15 Oct 2012 10:31:54 +0200 -Subject: [PATCH 038/131] partprobe: remove --no-update long option - -It was deprecated and scheduled for removal in 2009. -* partprobe/partprobe.c (long_options): Remove "no-update" entry. ---- - partprobe/partprobe.c | 3 --- - 1 file changed, 3 deletions(-) - -diff --git a/partprobe/partprobe.c b/partprobe/partprobe.c -index 8bccc4f..b8dca5e 100644 ---- a/partprobe/partprobe.c -+++ b/partprobe/partprobe.c -@@ -57,9 +57,6 @@ - - static struct option const long_options[] = - { -- /* Note: the --no-update option is deprecated, and deliberately -- * not documented. FIXME: remove --no-update in 2009. */ -- {"no-update", no_argument, NULL, 'd'}, - {"dry-run", no_argument, NULL, 'd'}, - {"summary", no_argument, NULL, 's'}, - {"help", no_argument, NULL, 'h'}, --- -1.9.3 - diff --git a/0039-doc-update-partprobe-manpage.patch b/0039-doc-update-partprobe-manpage.patch deleted file mode 100644 index a5f0633..0000000 --- a/0039-doc-update-partprobe-manpage.patch +++ /dev/null @@ -1,48 +0,0 @@ -From aec4b5228d1536452b1816731c41d9b37de2a25c Mon Sep 17 00:00:00 2001 -From: Petr Uzel -Date: Mon, 15 Oct 2012 10:31:53 +0200 -Subject: [PATCH 039/131] doc: update partprobe manpage - -* doc/C/partprobe.8: Add long options, REPORTING BUGS section -and adjust DESCRIPTION section because it wasn't quite correct. ---- - doc/C/partprobe.8 | 13 +++++++------ - 1 file changed, 7 insertions(+), 6 deletions(-) - -diff --git a/doc/C/partprobe.8 b/doc/C/partprobe.8 -index 6abf97d..48ae5dc 100644 ---- a/doc/C/partprobe.8 -+++ b/doc/C/partprobe.8 -@@ -31,22 +31,23 @@ command. - .\" \fI\fP escape sequences to invode bold face and italics, - .\" respectively. - \fBpartprobe\fP is a program that informs the operating system kernel of --partition table changes, by requesting that the operating system re-read --the partition table. -+partition table changes. - .SH OPTIONS - This program uses short UNIX style options. - .TP --.B \-d -+.B -d, --dry-run - Don't update the kernel. - .TP --.B \-s -+.B -s, --summary - Show a summary of devices and their partitions. - .TP --.B \-h -+.B -h, --help - Show summary of options. - .TP --.B \-v -+.B -v, --version - Show version of program. -+.SH REPORTING BUGS -+Report bugs to - .SH SEE ALSO - .BR parted (8). - .SH AUTHOR --- -1.9.3 - diff --git a/0040-partprobe-remove-partitions-when-there-is-no-partiti.patch b/0040-partprobe-remove-partitions-when-there-is-no-partiti.patch deleted file mode 100644 index ff90a4e..0000000 --- a/0040-partprobe-remove-partitions-when-there-is-no-partiti.patch +++ /dev/null @@ -1,67 +0,0 @@ -From 05917368a7867a17d6b2e0df16bf54239aa52107 Mon Sep 17 00:00:00 2001 -From: Petr Uzel -Date: Mon, 15 Oct 2012 10:31:52 +0200 -Subject: [PATCH 040/131] partprobe: remove partitions when there is no - partition table - -When partprobe detects no partition table on a device, it should -tell the kernel to drop partitions on that device, but it did not. -* parted/partprobe.c (process_dev): When ped_disk_probe fails, -create a dummy (empty) partition table and use that. -* NEWS (Bug fixes): Mention it. -Addresses: https://bugzilla.novell.com/783419 ---- - NEWS | 3 +++ - partprobe/partprobe.c | 21 ++++++++++++++++----- - 2 files changed, 19 insertions(+), 5 deletions(-) - -diff --git a/NEWS b/NEWS -index 4c4716d..293f5e4 100644 ---- a/NEWS -+++ b/NEWS -@@ -17,6 +17,9 @@ GNU parted NEWS -*- outline -*- - libparted: treat a disk with no pMBR as an msdos-labeled disk - even when it has valid GPT headers. - -+ partprobe now tells the kernel to forget about any partitions -+ on a device that has no recognizable partition table. -+ - ** Changes in behavior - - Added new Linux-specific partition GUID type code -diff --git a/partprobe/partprobe.c b/partprobe/partprobe.c -index b8dca5e..0919d3f 100644 ---- a/partprobe/partprobe.c -+++ b/partprobe/partprobe.c -@@ -106,12 +106,23 @@ process_dev (PedDevice* dev) - PedDisk* disk; - - disk_type = ped_disk_probe (dev); -- if (!disk_type || !strcmp (disk_type->name, "loop")) -+ if (disk_type && !strcmp (disk_type->name, "loop")) - return 1; -- -- disk = ped_disk_new (dev); -- if (!disk) -- goto error; -+ else if (!disk_type) { -+ /* Partition table not found, so create dummy, -+ empty one */ -+ disk_type = ped_disk_type_get("msdos"); -+ if (!disk_type) -+ goto error; -+ -+ disk = ped_disk_new_fresh (dev, disk_type); -+ if (!disk) -+ goto error_destroy_disk; -+ } else { -+ disk = ped_disk_new (dev); -+ if (!disk) -+ goto error; -+ } - if (!opt_no_inform) { - if (!ped_disk_commit_to_os (disk)) - goto error_destroy_disk; --- -1.9.3 - diff --git a/0041-maint-use-AM_V_GEN-to-cut-down-on-build-noise.patch b/0041-maint-use-AM_V_GEN-to-cut-down-on-build-noise.patch deleted file mode 100644 index 7537ef2..0000000 --- a/0041-maint-use-AM_V_GEN-to-cut-down-on-build-noise.patch +++ /dev/null @@ -1,65 +0,0 @@ -From c897203a7f65a05e57c67e6cddee3f70110d0824 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 17 Oct 2012 16:55:02 +0200 -Subject: [PATCH 041/131] maint: use $(AM_V_GEN) to cut down on build noise - -* doc/Makefile.am: Prefix each rule with $(AM_V_GEN). -* doc/po4a.mk (dist_man_MANS): Likewise. ---- - doc/Makefile.am | 2 +- - doc/po4a.mk | 8 ++++---- - 2 files changed, 5 insertions(+), 5 deletions(-) - -diff --git a/doc/Makefile.am b/doc/Makefile.am -index 08046d1..e773efa 100644 ---- a/doc/Makefile.am -+++ b/doc/Makefile.am -@@ -12,6 +12,6 @@ EXTRA_DIST = FAT \ - - .PHONY: updatepo - updatepo: -- list='$(SUBDIRS)'; for dir in $$list; do \ -+ $(AM_V_GEN)list='$(SUBDIRS)'; for dir in $$list; do \ - $(MAKE) -C "$$dir" updatepo; \ - done -diff --git a/doc/po4a.mk b/doc/po4a.mk -index b378121..aaf4024 100644 ---- a/doc/po4a.mk -+++ b/doc/po4a.mk -@@ -41,13 +41,13 @@ install-man: install-man1 install-man5 install-man8 - - # For each .po, try to generate the man page - all-local: -- for po in `ls -1 $(srcdir)/*.$(lang).po 2>/dev/null`; do \ -+ $(AM_V_GEN)for po in `ls -1 $(srcdir)/*.$(lang).po 2>/dev/null`; do \ - $(MAKE) $$(basename $${po%.$(lang).po}); \ - done - - # Remove the man pages that were generated from a .po - clean-local: -- for po in `ls -1 $(srcdir)/*.$(lang).po 2>/dev/null`; do \ -+ $(AM_V_GEN)for po in `ls -1 $(srcdir)/*.$(lang).po 2>/dev/null`; do \ - rm -f $$(basename $${po%.$(lang).po}); \ - done - -@@ -55,7 +55,7 @@ clean-local: - # Update the PO in srcdir, according to the POT in C. - # Based on the gettext po/Makefile.in.in - updatepo: -- tmpdir=`pwd`; \ -+ $(AM_V_GEN)tmpdir=`pwd`; \ - cd $(srcdir); \ - for po in *.$(lang).po; do \ - case "$$po" in '*'*) continue;; esac; \ -@@ -83,7 +83,7 @@ dist-hook: updatepo - - # Build the pages - partprobe.8: -- for locale in pt_BR ; do \ -+ $(AM_V_GEN)for locale in pt_BR ; do \ - po4a-translate -f man -m $(srcdir)/../C/$@ -p $@.$$locale.po -l $@ $(po4a_translate_options) ; \ - if [ -f $(srcdir)/$@.$$locale.po.addendum ]; then \ - po4a-translate -f man -m $(srcdir)/../C/$@ -p $@.$$locale.po -l $@ -a $(srcdir)/$@.$$locale.po.addendum $(po4a_translate_options) ; \ --- -1.9.3 - diff --git a/0042-maint-regenerate-.po-.pot-files.patch b/0042-maint-regenerate-.po-.pot-files.patch deleted file mode 100644 index a7f497f..0000000 --- a/0042-maint-regenerate-.po-.pot-files.patch +++ /dev/null @@ -1,337 +0,0 @@ -From d9f34625df17b30013e141516c2722b77b4b6eea Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 17 Oct 2012 23:07:55 +0200 -Subject: [PATCH 042/131] maint: regenerate .po, .pot files - ---- - doc/C/po/partprobe.8.pot | 59 ++++++++++++++++-------------- - doc/pt_BR/partprobe.8.pt_BR.po | 83 +++++++++++++++++++++++++++--------------- - 2 files changed, 85 insertions(+), 57 deletions(-) - -diff --git a/doc/C/po/partprobe.8.pot b/doc/C/po/partprobe.8.pot -index 19bd79f..d061382 100644 ---- a/doc/C/po/partprobe.8.pot -+++ b/doc/C/po/partprobe.8.pot -@@ -6,7 +6,7 @@ - msgid "" - msgstr "" - "Project-Id-Version: PACKAGE VERSION\n" --"POT-Creation-Date: 2011-02-26 06:06+0100\n" -+"POT-Creation-Date: 2012-10-17 21:43+0300\n" - "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" - "Last-Translator: FULL NAME \n" - "Language-Team: LANGUAGE \n" -@@ -93,106 +93,111 @@ msgstr "" - msgid "This manual page documents briefly the B command." - msgstr "" - --# type: Plain text - #. TeX users may be more comfortable with the \fB\fP and - #. \fI\fP escape sequences to invode bold face and italics, - #. respectively. - #. type: Plain text --#: partprobe.8:36 -+#: partprobe.8:35 - msgid "" - "B is a program that informs the operating system kernel of " --"partition table changes, by requesting that the operating system re-read the " --"partition table." -+"partition table changes." - msgstr "" - - # type: SH - #. type: SH --#: partprobe.8:36 -+#: partprobe.8:35 - #, no-wrap - msgid "OPTIONS" - msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:38 -+#: partprobe.8:37 - msgid "This program uses short UNIX style options." - msgstr "" - --# type: TP - #. type: TP --#: partprobe.8:38 -+#: partprobe.8:37 - #, no-wrap --msgid "B<-d>" -+msgid "B<-d, --dry-run>" - msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:41 -+#: partprobe.8:40 - msgid "Don't update the kernel." - msgstr "" - --# type: TP - #. type: TP --#: partprobe.8:41 -+#: partprobe.8:40 - #, no-wrap --msgid "B<-s>" -+msgid "B<-s, --summary>" - msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:44 -+#: partprobe.8:43 - msgid "Show a summary of devices and their partitions." - msgstr "" - --# type: TP - #. type: TP --#: partprobe.8:44 -+#: partprobe.8:43 - #, no-wrap --msgid "B<-h>" -+msgid "B<-h, --help>" - msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:47 -+#: partprobe.8:46 - msgid "Show summary of options." - msgstr "" - --# type: TP - #. type: TP --#: partprobe.8:47 -+#: partprobe.8:46 - #, no-wrap --msgid "B<-v>" -+msgid "B<-v, --version>" - msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:50 -+#: partprobe.8:49 - msgid "Show version of program." - msgstr "" - -+#. type: SH -+#: partprobe.8:49 -+#, no-wrap -+msgid "REPORTING BUGS" -+msgstr "" -+ -+#. type: Plain text -+#: partprobe.8:51 -+msgid "Report bugs to Ebug-parted@gnu.orgE" -+msgstr "" -+ - # type: SH - #. type: SH --#: partprobe.8:50 -+#: partprobe.8:51 - #, no-wrap - msgid "SEE ALSO" - msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:52 -+#: partprobe.8:53 - msgid "B(8)." - msgstr "" - - # type: SH - #. type: SH --#: partprobe.8:52 -+#: partprobe.8:53 - #, no-wrap - msgid "AUTHOR" - msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:54 -+#: partprobe.8:55 - msgid "" - "This manual page was written by Timshel Knoll Etimshel@debian.orgE, " - "for the Debian GNU/Linux system (but may be used by others)." -diff --git a/doc/pt_BR/partprobe.8.pt_BR.po b/doc/pt_BR/partprobe.8.pt_BR.po -index ffa47d7..4870d09 100644 ---- a/doc/pt_BR/partprobe.8.pt_BR.po -+++ b/doc/pt_BR/partprobe.8.pt_BR.po -@@ -5,7 +5,7 @@ - msgid "" - msgstr "" - "Project-Id-Version: PACKAGE VERSION\n" --"POT-Creation-Date: 2011-02-26 06:06+0100\n" -+"POT-Creation-Date: 2012-10-17 21:43+0300\n" - "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" - "Last-Translator: Tassia Camoes Araujo \n" - "Language-Team: l10n portuguese \n" -@@ -100,11 +100,11 @@ msgstr "Esta página de manual documenta brevemente o comando B" - #. \fI\fP escape sequences to invode bold face and italics, - #. respectively. - #. type: Plain text --#: partprobe.8:36 -+#: partprobe.8:35 -+#, fuzzy - msgid "" - "B is a program that informs the operating system kernel of " --"partition table changes, by requesting that the operating system re-read the " --"partition table." -+"partition table changes." - msgstr "" - "B é uma programa que informa ao kernel do sistema operacional " - "sobre mudanças na tabela de partição, requisitando que o sistema operacional " -@@ -112,95 +112,118 @@ msgstr "" - - # type: SH - #. type: SH --#: partprobe.8:36 -+#: partprobe.8:35 - #, no-wrap - msgid "OPTIONS" - msgstr "OPÇÕES" - - # type: Plain text - #. type: Plain text --#: partprobe.8:38 -+#: partprobe.8:37 - msgid "This program uses short UNIX style options." - msgstr "Este programa usa opções de estilo curtas do UNIX." - --# type: TP - #. type: TP --#: partprobe.8:38 -+#: partprobe.8:37 - #, no-wrap --msgid "B<-d>" --msgstr "B<-d>" -+msgid "B<-d, --dry-run>" -+msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:41 -+#: partprobe.8:40 - msgid "Don't update the kernel." - msgstr "Não atualiza o kernel." - --# type: TP - #. type: TP --#: partprobe.8:41 -+#: partprobe.8:40 - #, no-wrap --msgid "B<-s>" --msgstr "B<-s>" -+msgid "B<-s, --summary>" -+msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:44 -+#: partprobe.8:43 - msgid "Show a summary of devices and their partitions." - msgstr "Mostra um sumário dos dispositivos e suas partições." - --# type: TP - #. type: TP --#: partprobe.8:44 -+#: partprobe.8:43 - #, no-wrap --msgid "B<-h>" --msgstr "B<-h>" -+msgid "B<-h, --help>" -+msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:47 -+#: partprobe.8:46 - msgid "Show summary of options." - msgstr "Mostra sumário de opções." - --# type: TP - #. type: TP --#: partprobe.8:47 -+#: partprobe.8:46 - #, no-wrap --msgid "B<-v>" --msgstr "B<-v>" -+msgid "B<-v, --version>" -+msgstr "" - - # type: Plain text - #. type: Plain text --#: partprobe.8:50 -+#: partprobe.8:49 - msgid "Show version of program." - msgstr "Mostra versão do programa." - -+#. type: SH -+#: partprobe.8:49 -+#, no-wrap -+msgid "REPORTING BUGS" -+msgstr "" -+ -+#. type: Plain text -+#: partprobe.8:51 -+msgid "Report bugs to Ebug-parted@gnu.orgE" -+msgstr "" -+ - # type: SH - #. type: SH --#: partprobe.8:50 -+#: partprobe.8:51 - #, no-wrap - msgid "SEE ALSO" - msgstr "VEJA TAMBÉM" - - # type: Plain text - #. type: Plain text --#: partprobe.8:52 -+#: partprobe.8:53 - msgid "B(8)." - msgstr "B(8)." - - # type: SH - #. type: SH --#: partprobe.8:52 -+#: partprobe.8:53 - #, no-wrap - msgid "AUTHOR" - msgstr "AUTOR" - - # type: Plain text - #. type: Plain text --#: partprobe.8:54 -+#: partprobe.8:55 - msgid "" - "This manual page was written by Timshel Knoll Etimshel@debian.orgE, " - "for the Debian GNU/Linux system (but may be used by others)." - msgstr "" - "Esta página de manual foi escrita por Timshel Knoll Etimshel@debian." - "orgE, para o sistema Debian GNU/Linux (mas pode ser usado por outros)." -+ -+# type: TP -+#~ msgid "B<-d>" -+#~ msgstr "B<-d>" -+ -+# type: TP -+#~ msgid "B<-s>" -+#~ msgstr "B<-s>" -+ -+# type: TP -+#~ msgid "B<-h>" -+#~ msgstr "B<-h>" -+ -+# type: TP -+#~ msgid "B<-v>" -+#~ msgstr "B<-v>" --- -1.9.3 - diff --git a/0043-tests-cleanup-losetup-usage.patch b/0043-tests-cleanup-losetup-usage.patch deleted file mode 100644 index 07aa905..0000000 --- a/0043-tests-cleanup-losetup-usage.patch +++ /dev/null @@ -1,83 +0,0 @@ -From 2ab9f04692e74c8b1daae68f1c22c5723f6c39ef Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 17 Oct 2012 21:42:12 +0200 -Subject: [PATCH 043/131] tests: cleanup losetup usage - -The unsafe_losetup_ function was failing because losetup didn't -recognize that the 'private' /dev/loopX devices were the same as -/dev/loopX, it would fail even if one was in use. Switch to using -losetup --show which is a cleaner solution. -Also use sparse file for loop_setup to save space. -* tests/t-lvm.sh (unsafe_losetup_): Remove function. -(loop_setup_): Use losetup's --show option instead. -Use dd with /dev/null, not /dev/zero. -* tests/t6001-psep.sh: Use loop_setup_ rather than losetup --show. ---- - tests/t-lvm.sh | 23 ++--------------------- - tests/t6001-psep.sh | 8 ++------ - 2 files changed, 4 insertions(+), 27 deletions(-) - -diff --git a/tests/t-lvm.sh b/tests/t-lvm.sh -index cf1b8b8..001523b 100644 ---- a/tests/t-lvm.sh -+++ b/tests/t-lvm.sh -@@ -13,33 +13,14 @@ - - export LVM_SUPPRESS_FD_WARNINGS=1 - --unsafe_losetup_() --{ -- f=$1 -- -- G_dev_=/dev -- -- # Iterate through $G_dev_/loop{,/}{0,1,2,3,4,5,6,7,8,9} -- for slash in '' /; do -- for i in 0 1 2 3 4 5 6 7 8 9; do -- dev=$G_dev_/loop$slash$i -- losetup $dev 1>&2 && continue; -- losetup "$dev" "$f" > /dev/null && { echo "$dev"; return 0; } -- break -- done -- done -- -- return 1 --} -- - loop_setup_() - { - file=$1 -- dd if=/dev/zero of="$file" bs=1M count=1 seek=1000 > /dev/null 2>&1 \ -+ dd if=/dev/null of="$file" bs=1M count=1 seek=1000 > /dev/null 2>&1 \ - || { warn_ "loop_setup_ failed: Unable to create tmp file $file"; return 1; } - - # NOTE: this requires a new enough version of losetup -- dev=$(unsafe_losetup_ "$file") \ -+ dev=$(losetup --show -f "$file") \ - || { warn_ "loop_setup_ failed: Unable to create loopback device"; return 1; } - - echo "$dev" -diff --git a/tests/t6001-psep.sh b/tests/t6001-psep.sh -index 490c6d2..1859ac9 100644 ---- a/tests/t6001-psep.sh -+++ b/tests/t6001-psep.sh -@@ -44,14 +44,10 @@ cleanup_fn_() { - # create a file of size N bytes - N=10M - --# create the test file --f1=$(pwd)/1; dd if=/dev/null of=$f1 bs=1 seek=$N 2> /dev/null || fail=1 --f2=$(pwd)/2; dd if=/dev/null of=$f2 bs=1 seek=$N 2> /dev/null || fail=1 -- --d1=$(loop_setup_ "$f1") \ -+f1=$(pwd)/1; d1=$(loop_setup_ "$f1") \ - || skip_ "is this partition mounted with 'nodev'?" - --d2=$(loop_setup_ "$f2") \ -+f2=$(pwd)/2 ;d2=$(loop_setup_ "$f2") \ - || skip_ "is this partition mounted with 'nodev'?" - - dmsetup_cmd="0 `blockdev --getsz $d1` linear $d1 0" --- -1.9.3 - diff --git a/0044-build-default-to-enable-gcc-warnings-in-a-git-tree.patch b/0044-build-default-to-enable-gcc-warnings-in-a-git-tree.patch deleted file mode 100644 index 24d7e91..0000000 --- a/0044-build-default-to-enable-gcc-warnings-in-a-git-tree.patch +++ /dev/null @@ -1,34 +0,0 @@ -From d3a81337ff149294b7cf63c45a61ffa24fa542c5 Mon Sep 17 00:00:00 2001 -From: Eric Blake -Date: Tue, 23 Oct 2012 11:07:29 +0200 -Subject: [PATCH 044/131] build: default to --enable-gcc-warnings in a git tree - -Anyone building from cloned sources can be assumed to have a new -enough environment, such that enabling gcc warnings by default will -be useful. Tarballs still default to no warnings, and the default -can still be overridden with --disable-gcc-warnings. -* configure.ac (gl_gcc_warnings): Set default based on environment. ---- - configure.ac | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/configure.ac b/configure.ac -index 832fc20..417f325 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -187,7 +187,11 @@ AC_ARG_ENABLE([gcc-warnings], - *) AC_MSG_ERROR([bad value $enableval for gcc-warnings option]) ;; - esac - gl_gcc_warnings=$enableval], -- [gl_gcc_warnings=no] -+ [if test -d "$srcdir"/.git; then -+ gl_gcc_warnings=yes -+ else -+ gl_gcc_warnings=no -+ fi] - ) - - if test "$gl_gcc_warnings" = yes; then --- -1.9.3 - diff --git a/0045-libparted-refactor-device-mapper-partition-sync-code.patch b/0045-libparted-refactor-device-mapper-partition-sync-code.patch deleted file mode 100644 index fcb8b96..0000000 --- a/0045-libparted-refactor-device-mapper-partition-sync-code.patch +++ /dev/null @@ -1,638 +0,0 @@ -From f0c0d53f998964e187f59de32ac92a2c0e2d5da9 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 14 Oct 2012 23:59:58 -0400 -Subject: [PATCH 045/131] libparted: refactor device-mapper partition sync code - -The device-mapper partition sync code was still using the remove all -partitions, then add new partitions method. Refactor to use the same -algorithm as regular disks: try to remove all, and ignore any that could -not be removed but have not changed. ---- - NEWS | 3 + - libparted/arch/linux.c | 405 ++++++++++++++++++++++--------------------------- - tests/Makefile.am | 1 + - tests/t6002-dm-busy.sh | 92 +++++++++++ - 4 files changed, 274 insertions(+), 227 deletions(-) - create mode 100644 tests/t6002-dm-busy.sh - -diff --git a/NEWS b/NEWS -index 293f5e4..a40d69b 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: Don't fail to manipulate partitions on dmraid disks that -+ have other partitions in use. -+ - libparted: mac: a MAC partition table could have a block_size larger - than the one the kernel told us about. Upon reading that partition - table, libparted would ask if it's ok to use the larger block size. -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index e2c4139..70b26a9 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -285,7 +285,7 @@ struct blkdev_ioctl_param { - /* Maximum number of partitions supported by linux. */ - #define MAX_NUM_PARTS 64 - --static char* _device_get_part_path (PedDevice* dev, int num); -+static char* _device_get_part_path (PedDevice const *dev, int num); - static int _partition_is_mounted_by_path (const char* path); - - static int -@@ -2225,28 +2225,53 @@ zasprintf (const char *format, ...) - return r < 0 ? NULL : resultp; - } - --static char* --_device_get_part_path (PedDevice *dev, int num) -+static char * -+dm_canonical_path (PedDevice const *dev) - { -- size_t path_len = strlen (dev->path); -+ LinuxSpecific const *arch_specific = LINUX_SPECIFIC (dev); - -+ /* Get map name from devicemapper */ -+ struct dm_task *task = dm_task_create (DM_DEVICE_INFO); -+ if (!task) -+ goto err; -+ if (!dm_task_set_major_minor (task, arch_specific->major, -+ arch_specific->minor, 0)) -+ goto err; -+ if (!dm_task_run(task)) -+ goto err; -+ char *dev_name = zasprintf ("/dev/mapper/%s", dm_task_get_name (task)); -+ if (dev_name == NULL) -+ goto err; -+ dm_task_destroy (task); -+ return dev_name; -+err: -+ return NULL; -+} -+ -+static char* -+_device_get_part_path (PedDevice const *dev, int num) -+{ -+ char *devpath = (dev->type == PED_DEVICE_DM -+ ? dm_canonical_path (dev) : dev->path); -+ size_t path_len = strlen (devpath); - char *result; - /* Check for devfs-style /disc => /partN transformation - unconditionally; the system might be using udev with devfs rules, - and if not the test is harmless. */ -- if (5 < path_len && !strcmp (dev->path + path_len - 5, "/disc")) { -+ if (5 < path_len && !strcmp (devpath + path_len - 5, "/disc")) { - /* replace /disc with /part%d */ - result = zasprintf ("%.*s/part%d", -- (int) (path_len - 5), dev->path, num); -+ (int) (path_len - 5), devpath, num); - } else { - char const *p = (dev->type == PED_DEVICE_DAC960 - || dev->type == PED_DEVICE_CPQARRAY - || dev->type == PED_DEVICE_ATARAID -- || isdigit (dev->path[path_len - 1]) -+ || isdigit (devpath[path_len - 1]) - ? "p" : ""); -- result = zasprintf ("%s%s%d", dev->path, p, num); -+ result = zasprintf ("%s%s%d", devpath, p, num); - } -- -+ if (dev->type == PED_DEVICE_DM) -+ free (devpath); - return result; - } - -@@ -2530,6 +2555,8 @@ static unsigned int - _device_get_partition_range(PedDevice const* dev) - { - int range; -+ if (dev->type == PED_DEVICE_DM) -+ return MAX_NUM_PARTS; - bool ok = _sysfs_int_entry_from_dev(dev, "ext_range", &range); - - if (!ok) -@@ -2538,6 +2565,128 @@ _device_get_partition_range(PedDevice const* dev) - return range > 1 ? range : 0; - } - -+#ifdef ENABLE_DEVICE_MAPPER -+static int -+_dm_remove_partition(PedDisk* disk, int partno) -+{ -+ int rc; -+ char *part_name = _device_get_part_path (disk->dev, partno); -+ -+ int fd = open (part_name, O_RDONLY | O_EXCL); -+ if (fd == -1) { -+ if (errno == ENOENT) -+ errno = ENXIO; /* nothing to remove, device already doesn't exist */ -+ free (part_name); -+ return 0; -+ } -+ close (fd); -+ struct dm_task *task = dm_task_create(DM_DEVICE_REMOVE); -+ if (!task) { -+ free (part_name); -+ return 0; -+ } -+ dm_task_set_name (task, part_name); -+ rc = dm_task_run(task); -+ dm_task_update_nodes(); -+ dm_task_destroy(task); -+ free (part_name); -+ if (!rc) -+ return 0; -+ -+ return 1; -+} -+ -+static bool -+_dm_get_partition_start_and_length(PedPartition const *part, -+ unsigned long long *start, -+ unsigned long long *length) -+{ -+ struct dm_task* task = NULL; -+ int rc = 0; -+ -+ if (!(task = dm_task_create(DM_DEVICE_TABLE))) -+ return 0; -+ char *path = _device_get_part_path (part->disk->dev, part->num); -+ PED_ASSERT(path); -+ dm_task_set_name(task, path); -+ if (!dm_task_run(task)) -+ goto err; -+ -+ int major, minor; -+ char *params; -+ char *target_type; -+ dm_get_next_target(task, NULL, (uint64_t *)start, (uint64_t *)length, &target_type, ¶ms); -+ if (sscanf (params, "%d:%d %Ld", &major, &minor, start) != 3) -+ goto err; -+ rc = 1; -+err: -+ free (path); -+ dm_task_destroy(task); -+ return rc; -+} -+ -+ -+static int -+_dm_add_partition (PedDisk* disk, const PedPartition* part) -+{ -+ LinuxSpecific* arch_specific = LINUX_SPECIFIC (disk->dev); -+ char *params = NULL; -+ char *vol_name = NULL; -+ -+ /* Get map name from devicemapper */ -+ struct dm_task *task = dm_task_create (DM_DEVICE_INFO); -+ if (!task) -+ goto err; -+ -+ if (!dm_task_set_major_minor (task, arch_specific->major, -+ arch_specific->minor, 0)) -+ goto err; -+ -+ if (!dm_task_run(task)) -+ goto err; -+ -+ const char *dev_name = dm_task_get_name (task); -+ size_t name_len = strlen (dev_name); -+ vol_name = zasprintf ("%s%s%d", -+ dev_name, -+ isdigit (dev_name[name_len - 1]) ? "p" : "", -+ part->num); -+ if (vol_name == NULL) -+ goto err; -+ -+ /* Caution: dm_task_destroy frees dev_name. */ -+ dm_task_destroy (task); -+ task = NULL; -+ if ( ! (params = zasprintf ("%d:%d %lld", arch_specific->major, -+ arch_specific->minor, part->geom.start))) -+ goto err; -+ -+ task = dm_task_create (DM_DEVICE_CREATE); -+ if (!task) -+ goto err; -+ -+ dm_task_set_name (task, vol_name); -+ dm_task_add_target (task, 0, part->geom.length, -+ "linear", params); -+ if (dm_task_run (task)) { -+ dm_task_update_nodes (); -+ dm_task_destroy (task); -+ free (params); -+ free (vol_name); -+ return 1; -+ } else { -+ _dm_remove_partition (disk, part->num); -+ } -+err: -+ dm_task_update_nodes(); -+ if (task) -+ dm_task_destroy (task); -+ free (params); -+ free (vol_name); -+ return 0; -+} -+#endif -+ - /* - * Sync the partition table in two step process: - * 1. Remove all of the partitions from the kernel's tables, but do not attempt -@@ -2558,8 +2707,23 @@ _disk_sync_part_table (PedDisk* disk) - PED_ASSERT(disk != NULL); - PED_ASSERT(disk->dev != NULL); - int lpn; -- - unsigned int part_range = _device_get_partition_range(disk->dev); -+ int (*add_partition)(PedDisk* disk, const PedPartition *part); -+ int (*remove_partition)(PedDisk* disk, int partno); -+ bool (*get_partition_start_and_length)(PedPartition const *part, -+ unsigned long long *start, -+ unsigned long long *length); -+ -+ -+ if (disk->dev->type == PED_DEVICE_DM) { -+ add_partition = _dm_add_partition; -+ remove_partition = _dm_remove_partition; -+ get_partition_start_and_length = _dm_get_partition_start_and_length; -+ } else { -+ add_partition = _blkpg_add_partition; -+ remove_partition = _blkpg_remove_partition; -+ get_partition_start_and_length = _kernel_get_partition_start_and_length; -+ } - - /* lpn = largest partition number. */ - if (ped_disk_get_max_supported_partition_count(disk, &lpn)) -@@ -2594,7 +2758,7 @@ _disk_sync_part_table (PedDisk* disk) - int j; - for (j = 0; j < lpn; j++) { - if (!ok[j]) { -- ok[j] = _blkpg_remove_partition (disk, j + 1); -+ ok[j] = remove_partition (disk, j + 1); - errnums[j] = errno; - if (!ok[j] && errnums[j] == EBUSY) - busy = true; -@@ -2611,8 +2775,8 @@ _disk_sync_part_table (PedDisk* disk) - unsigned long long length; - unsigned long long start; - /* get start and length of existing partition */ -- if (!_kernel_get_partition_start_and_length(part, -- &start, &length)) -+ if (!get_partition_start_and_length(part, -+ &start, &length)) - goto cleanup; - if (start == part->geom.start - && length == part->geom.length) -@@ -2625,7 +2789,7 @@ _disk_sync_part_table (PedDisk* disk) - } - - /* add the (possibly modified or new) partition */ -- if (!_blkpg_add_partition (disk, part)) { -+ if (!add_partition (disk, part)) { - ped_exception_throw ( - PED_EXCEPTION_ERROR, - PED_EXCEPTION_RETRY_CANCEL, -@@ -2671,215 +2835,6 @@ _disk_sync_part_table (PedDisk* disk) - return ret; - } - --#ifdef ENABLE_DEVICE_MAPPER --static int --_dm_remove_map_name(char *name) --{ -- struct dm_task *task = NULL; -- int rc; -- -- task = dm_task_create(DM_DEVICE_REMOVE); -- if (!task) -- return 1; -- -- dm_task_set_name (task, name); -- -- rc = dm_task_run(task); -- dm_task_update_nodes(); -- dm_task_destroy(task); -- if (!rc) -- return 1; -- -- return 0; --} -- --static int --_dm_is_part (struct dm_info *this, char *name) --{ -- struct dm_task* task = NULL; -- struct dm_info* info = alloca(sizeof *info); -- struct dm_deps* deps = NULL; -- int rc = 0; -- unsigned int i; -- -- task = dm_task_create(DM_DEVICE_DEPS); -- if (!task) -- return 0; -- -- dm_task_set_name(task, name); -- if (!dm_task_run(task)) -- goto err; -- -- memset(info, '\0', sizeof *info); -- dm_task_get_info(task, info); -- if (!info->exists) -- goto err; -- -- deps = dm_task_get_deps(task); -- if (!deps) -- goto err; -- -- for (i = 0; i < deps->count; i++) { -- unsigned int ma = major(deps->device[i]), -- mi = minor(deps->device[i]); -- -- if (ma == this->major && mi == this->minor) -- rc = 1; -- } -- --err: -- dm_task_destroy(task); -- return rc; --} -- --static int --_dm_remove_parts (PedDevice* dev) --{ -- struct dm_task* task = NULL; -- struct dm_info* info = alloca(sizeof *info); -- struct dm_names* names = NULL; -- unsigned int next = 0; -- int rc; -- LinuxSpecific* arch_specific = LINUX_SPECIFIC (dev); -- -- task = dm_task_create(DM_DEVICE_LIST); -- if (!task) -- goto err; -- -- if (!dm_task_set_major_minor (task, arch_specific->major, -- arch_specific->minor, 0)) -- goto err; -- -- if (!dm_task_run(task)) -- goto err; -- -- memset(info, '\0', sizeof *info); -- dm_task_get_info(task, info); -- if (!info->exists) -- goto err; -- -- names = dm_task_get_names(task); -- if (!names) -- goto err; -- -- rc = 0; -- do { -- names = (void *) ((char *) names + next); -- -- if (_dm_is_part(info, names->name)) -- rc += _dm_remove_map_name(names->name); -- -- next = names->next; -- } while (next); -- -- dm_task_update_nodes(); -- dm_task_destroy(task); -- task = NULL; -- -- if (!rc) -- return 1; --err: -- if (task) -- dm_task_destroy(task); -- ped_exception_throw (PED_EXCEPTION_WARNING, PED_EXCEPTION_IGNORE, -- _("parted was unable to re-read the partition " -- "table on %s (%s). This means Linux won't know " -- "anything about the modifications you made. "), -- dev->path, strerror (errno)); -- return 0; --} -- --static int --_dm_add_partition (PedDisk* disk, PedPartition* part) --{ -- char* vol_name = NULL; -- const char* dev_name = NULL; -- char* params = NULL; -- LinuxSpecific* arch_specific = LINUX_SPECIFIC (disk->dev); -- -- /* Get map name from devicemapper */ -- struct dm_task *task = dm_task_create (DM_DEVICE_INFO); -- if (!task) -- goto err; -- -- if (!dm_task_set_major_minor (task, arch_specific->major, -- arch_specific->minor, 0)) -- goto err; -- -- if (!dm_task_run(task)) -- goto err; -- -- dev_name = dm_task_get_name (task); -- -- if (isdigit (dev_name[strlen (dev_name) - 1])) { -- if ( ! (vol_name = zasprintf ("%sp%d", dev_name, part->num))) -- goto err; -- } else if ( ! (vol_name = zasprintf ("%s%d", dev_name, part->num))) -- goto err; -- -- /* Caution: dm_task_destroy frees dev_name. */ -- dm_task_destroy (task); -- task = NULL; -- -- if ( ! (params = zasprintf ("%d:%d %lld", arch_specific->major, -- arch_specific->minor, part->geom.start))) -- goto err; -- -- task = dm_task_create (DM_DEVICE_CREATE); -- if (!task) -- goto err; -- -- dm_task_set_name (task, vol_name); -- dm_task_add_target (task, 0, part->geom.length, -- "linear", params); -- if (dm_task_run (task)) { -- //printf("0 %ld linear %s\n", part->geom.length, params); -- dm_task_update_nodes(); -- dm_task_destroy(task); -- free(params); -- free(vol_name); -- return 1; -- } else { -- _dm_remove_map_name(vol_name); -- } --err: -- dm_task_update_nodes(); -- if (task) -- dm_task_destroy (task); -- free (params); -- free (vol_name); -- return 0; --} -- --static int --_dm_reread_part_table (PedDisk* disk) --{ -- int largest_partnum = ped_disk_get_last_partition_num (disk); -- if (largest_partnum <= 0) -- return 1; -- -- int rc = 1; -- int last = PED_MIN (largest_partnum, 16); -- int i; -- -- sync(); -- if (!_dm_remove_parts(disk->dev)) -- rc = 0; -- -- for (i = 1; i <= last; i++) { -- PedPartition* part; -- -- part = ped_disk_get_partition (disk, i); -- if (!part) -- continue; -- -- if (!_dm_add_partition (disk, part)) -- rc = 0; -- } -- return rc; --} --#endif -- - static int - _have_blkpg () - { -@@ -2897,10 +2852,6 @@ _have_blkpg () - static int - linux_disk_commit (PedDisk* disk) - { --#ifdef ENABLE_DEVICE_MAPPER -- if (disk->dev->type == PED_DEVICE_DM) -- return _dm_reread_part_table (disk); --#endif - if (disk->dev->type != PED_DEVICE_FILE) { - - /* We now require BLKPG support. If this assertion fails, -diff --git a/tests/Makefile.am b/tests/Makefile.am -index cdc1c4b..4649c0a 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -58,6 +58,7 @@ TESTS = \ - t5000-tags.sh \ - t6000-dm.sh \ - t6001-psep.sh \ -+ t6002-dm-busy.sh \ - t6100-mdraid-partitions.sh \ - t7000-scripting.sh \ - t8000-loop.sh \ -diff --git a/tests/t6002-dm-busy.sh b/tests/t6002-dm-busy.sh -new file mode 100644 -index 0000000..9807b40 ---- /dev/null -+++ b/tests/t6002-dm-busy.sh -@@ -0,0 +1,92 @@ -+#!/bin/sh -+# ensure that parted can alter a partition on a dmraid disk -+# while another one is mounted -+ -+# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+ -+require_root_ -+ -+# We could make this work for arbitrary sector size, but I'm lazy. -+require_512_byte_sector_size_ -+ -+test "x$ENABLE_DEVICE_MAPPER" = xyes \ -+ || skip_ "no device-mapper support" -+ -+# Device maps names - should be random to not conflict with existing ones on -+# the system -+linear_=plinear-$$ -+ -+d1= -+f1= -+dev= -+cleanup_fn_() { -+ umount "${dev}p2" > /dev/null 2>&1 -+ dmsetup remove ${linear_}p1 -+ dmsetup remove ${linear_}p2 -+ dmsetup remove $linear_ -+ test -n "$d1" && losetup -d "$d1" -+ rm -f "$f1" -+} -+ -+f1=$(pwd)/1; d1=$(loop_setup_ "$f1") \ -+ || fail=1 -+ -+# setup: create a mapping -+n=204800 -+echo "0 $n linear $d1 0" | dmsetup create $linear_ || fail=1 -+dev="/dev/mapper/$linear_" -+ -+# Create msdos partition table -+parted -s $dev mklabel msdos > out 2>&1 || fail=1 -+compare /dev/null out || fail=1 -+ -+parted -s $dev -a none mkpart primary fat32 1s 1000s > out 2>&1 || fail=1 -+compare /dev/null out || fail=1 -+ -+parted -s $dev -a none mkpart primary fat32 1001s 200000s > out 2>&1 || fail=1 -+compare /dev/null out || fail=1 -+ -+# wait for new partition device to appear -+wait_for_dev_to_appear_ ${dev}p2 || fail_ ${dev}p2 did not appear -+ -+mkfs.vfat -F 32 ${dev}p2 || fail_ mkfs.vfat failed -+ -+mount_point=$(pwd)/mnt -+ -+mkdir $mount_point || fail=1 -+mount "${dev}p2" "$mount_point" || fail=1 -+ -+# Removal of unmounted partition must succeed. -+parted -s "$dev" rm 1 > /dev/null 2>&1 || fail=1 -+ -+# Removal of mounted partition must fail. -+parted -s "$dev" rm 2 > /dev/null 2>&1 && fail=1 -+ -+parted -m -s "$dev" u s print > out 2>&1 || fail=1 -+sed "s,^$dev,DEV," out > k; mv k out -+ -+# Create expected output file. -+cat <> exp || fail=1 -+BYT; -+DEV:${n}s:dm:512:512:msdos:Linux device-mapper (linear):; -+2:1001s:200000s:199000s:fat32::lba; -+EOF -+ -+compare exp out || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0046-libparted-remove-extraneous-blkpg-add-partition-ped-.patch b/0046-libparted-remove-extraneous-blkpg-add-partition-ped-.patch deleted file mode 100644 index 4d7194c..0000000 --- a/0046-libparted-remove-extraneous-blkpg-add-partition-ped-.patch +++ /dev/null @@ -1,71 +0,0 @@ -From f87ff28d1aa8eff085e737ab22d031b0519e5510 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 14 Oct 2012 23:59:59 -0400 -Subject: [PATCH 046/131] libparted: remove extraneous blkpg add partition ped - exception - -_blkpg_add_partition was throwing an exception if it failed to add the -new partition, in addition to _disk_sync_part_table throwing one, and -then bailing out. Instead of bailing out, just log the error for -reporting later and continue. ---- - libparted/arch/linux.c | 21 +++------------------ - tests/t2310-dos-extended-2-sector-min-offset.sh | 3 +-- - 2 files changed, 4 insertions(+), 20 deletions(-) - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 70b26a9..5721d4b 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2407,18 +2407,7 @@ _blkpg_add_partition (PedDisk* disk, const PedPartition *part) - - if (!_blkpg_part_command (disk->dev, &linux_part, - BLKPG_ADD_PARTITION)) { -- return ped_exception_throw ( -- PED_EXCEPTION_ERROR, -- PED_EXCEPTION_IGNORE_CANCEL, -- _("Error informing the kernel about modifications to " -- "partition %s -- %s. This means Linux won't know " -- "about any changes you made to %s until you reboot " -- "-- so you shouldn't mount it or use it in any way " -- "before rebooting."), -- linux_part.devname, -- strerror (errno), -- linux_part.devname) -- == PED_EXCEPTION_IGNORE; -+ return 0; - } - - return 1; -@@ -2790,12 +2779,8 @@ _disk_sync_part_table (PedDisk* disk) - - /* add the (possibly modified or new) partition */ - if (!add_partition (disk, part)) { -- ped_exception_throw ( -- PED_EXCEPTION_ERROR, -- PED_EXCEPTION_RETRY_CANCEL, -- _("Failed to add partition %d (%s)"), -- i, strerror (errno)); -- goto cleanup; -+ ok[i - 1] = 0; -+ errnums[i - 1] = errno; - } - } - } -diff --git a/tests/t2310-dos-extended-2-sector-min-offset.sh b/tests/t2310-dos-extended-2-sector-min-offset.sh -index 89453ae..17c777c 100644 ---- a/tests/t2310-dos-extended-2-sector-min-offset.sh -+++ b/tests/t2310-dos-extended-2-sector-min-offset.sh -@@ -39,8 +39,7 @@ $scsi_dev:2048s:scsi:512:512:msdos:Linux scsi_debug:; - EOF - - cat < err.exp || framework_failure --Error: Error informing the kernel about modifications to partition $p5 -- Device or resource busy. This means Linux won't know about any changes you made to $p5 until you reboot -- so you shouldn't mount it or use it in any way before rebooting. --Error: Failed to add partition 5 (Device or resource busy) -+Error: Partition(s) 5 on $scsi_dev have been written, but we have been unable to inform the kernel of the change, probably because it/they are in use. As a result, the old partition(s) will remain in use. You should reboot now before making further changes. - EOF - - # Create a DOS label with an extended partition starting at sector 64. --- -1.9.3 - diff --git a/0047-libparted-don-t-probe-every-dm-device-in-probe_all.patch b/0047-libparted-don-t-probe-every-dm-device-in-probe_all.patch deleted file mode 100644 index e4884bd..0000000 --- a/0047-libparted-don-t-probe-every-dm-device-in-probe_all.patch +++ /dev/null @@ -1,225 +0,0 @@ -From 3cb820632a13a91e0c2e579aedbe8e86b4f0040e Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Fri, 19 Oct 2012 17:32:00 +0200 -Subject: [PATCH 047/131] libparted: don't probe every dm device in probe_all - -We were probing every dm device. Only probe dmraid whole disk -(non-partition) devices instead. This removes the clutter of -LVM logical volumes, and dmraid partitions from the list, which -usually do not make sense to partition. - -* NEWS (Changes in behavior): Mention it. -* libparted/arch/linux.c (_is_dmraid_device): New function. -(_dm_is_part): Likewise. -(_probe_dm_devices): Use the latter. -* tests/t6003-dm-hide.sh: New test. -* tests/Makefile.am (TESTS): Add it. ---- - NEWS | 3 ++ - libparted/arch/linux.c | 81 +++++++++++++++++++++++++++++++++++++++++++++++++- - tests/Makefile.am | 1 + - tests/t6003-dm-hide.sh | 60 +++++++++++++++++++++++++++++++++++++ - 4 files changed, 144 insertions(+), 1 deletion(-) - create mode 100644 tests/t6003-dm-hide.sh - -diff --git a/NEWS b/NEWS -index a40d69b..89541fd 100644 ---- a/NEWS -+++ b/NEWS -@@ -25,6 +25,9 @@ GNU parted NEWS -*- outline -*- - - ** Changes in behavior - -+ parted -l no longer lists device-mapper devices other than -+ dmraid whole disks. -+ - Added new Linux-specific partition GUID type code - (0FC63DAF-8483-4772-8E79-3D69D8477DE4) for Linux filesystem data on GPT - disks. This type code is now assigned as the default partition type code -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 5721d4b..083591f 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -65,6 +65,8 @@ - # define _GL_ATTRIBUTE_FORMAT(spec) /* empty */ - #endif - -+#define STRPREFIX(a, b) (strncmp (a, b, strlen (b)) == 0) -+ - #define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c)) - - #ifndef __NR__llseek -@@ -478,6 +480,82 @@ bad: - return r; - } - -+/* Return nonzero if device-mapper device, DEVPATH, is part of a dmraid -+ array. Use the heuristic of checking for the string "DMRAID-" at the -+ start of its UUID. */ -+static int -+_is_dmraid_device (const char *devpath) -+{ -+ int rc = 0; -+ -+ char const *dm_name = strrchr (devpath, '/'); -+ char const *dm_basename = dm_name && *(++dm_name) ? dm_name : devpath; -+ struct dm_task *task = dm_task_create (DM_DEVICE_DEPS); -+ if (!task) -+ return 0; -+ -+ dm_task_set_name (task, dm_basename); -+ if (!dm_task_run (task)) -+ goto err; -+ -+ const char *dmraid_uuid = dm_task_get_uuid (task); -+ if (STRPREFIX (dmraid_uuid, "DMRAID-")) -+ rc = 1; -+ -+err: -+ dm_task_destroy (task); -+ return rc; -+} -+ -+/* We consider a dm device that is a linear mapping with a * -+ * single target that also is a dm device to be a partition */ -+ -+static int -+_dm_is_part (const char *path) -+{ -+ int rc = 0; -+ struct dm_task *task = dm_task_create (DM_DEVICE_DEPS); -+ if (!task) -+ return 0; -+ -+ dm_task_set_name(task, path); -+ if (!dm_task_run(task)) -+ goto err; -+ -+ struct dm_info *info = alloca (sizeof *info); -+ memset(info, '\0', sizeof *info); -+ dm_task_get_info (task, info); -+ if (!info->exists) -+ goto err; -+ -+ struct dm_deps *deps = dm_task_get_deps (task); -+ if (!deps) -+ goto err; -+ -+ if (deps->count != 1) -+ goto err; -+ if (!_is_dm_major (major (deps->device[0]))) -+ goto err; -+ dm_task_destroy (task); -+ if (!(task = dm_task_create (DM_DEVICE_TABLE))) -+ return 0; -+ dm_task_set_name (task, path); -+ if (!dm_task_run (task)) -+ goto err; -+ -+ char *target_type = NULL; -+ char *params = NULL; -+ uint64_t start, length; -+ -+ dm_get_next_target (task, NULL, &start, &length, &target_type, ¶ms); -+ if (strcmp (target_type, "linear")) -+ goto err; -+ rc = 1; -+ -+err: -+ dm_task_destroy(task); -+ return rc; -+} - - static int - _probe_dm_devices () -@@ -504,7 +582,8 @@ _probe_dm_devices () - if (stat (buf, &st) != 0) - continue; - -- if (_is_dm_major(major(st.st_rdev))) -+ if (_is_dm_major(major(st.st_rdev)) && _is_dmraid_device (buf) -+ && !_dm_is_part(buf)) - _ped_device_probe (buf); - } - closedir (mapper_dir); -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 4649c0a..4ec08da 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -59,6 +59,7 @@ TESTS = \ - t6000-dm.sh \ - t6001-psep.sh \ - t6002-dm-busy.sh \ -+ t6003-dm-hide.sh \ - t6100-mdraid-partitions.sh \ - t7000-scripting.sh \ - t8000-loop.sh \ -diff --git a/tests/t6003-dm-hide.sh b/tests/t6003-dm-hide.sh -new file mode 100644 -index 0000000..3cfdc43 ---- /dev/null -+++ b/tests/t6003-dm-hide.sh -@@ -0,0 +1,60 @@ -+#!/bin/sh -+# ensure that parted -l only shows dmraid device-mapper devices -+ -+# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+ -+require_root_ -+lvm_init_root_dir_ -+ -+test "x$ENABLE_DEVICE_MAPPER" = xyes \ -+ || skip_ "no device-mapper support" -+ -+# Device maps names - should be random to not conflict with existing ones on -+# the system -+linear_=plinear-$$ -+ -+d1= -+f1= -+dev= -+cleanup_fn_() { -+ dmsetup remove $linear_ -+ test -n "$d1" && losetup -d "$d1" -+ rm -f "$f1" -+} -+ -+f1=$(pwd)/1; d1=$(loop_setup_ "$f1") \ -+ || fail=1 -+ -+# setup: create a mapping -+echo "0 2048 linear $d1 0" | dmsetup create $linear_ || fail=1 -+dev="$DM_DEV_DIR/mapper/$linear_" -+ -+# device should not show up -+ -+parted -l >out 2>&1 -+! grep $linear_ out || fail=1 -+ -+dmsetup remove $linear_ -+echo "0 2048 linear $d1 0" | dmsetup create $linear_ -u "DMRAID-fake" || fail=1 -+ -+# device should now show up -+ -+parted -l >out 2>&1 -+grep $linear_ out || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0048-tests-make-t6003-dm-hide-work-reliably-on-F17.patch b/0048-tests-make-t6003-dm-hide-work-reliably-on-F17.patch deleted file mode 100644 index 0c4930b..0000000 --- a/0048-tests-make-t6003-dm-hide-work-reliably-on-F17.patch +++ /dev/null @@ -1,71 +0,0 @@ -From 2224076fef1a54391cf090149ba9308ae90067eb Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Fri, 19 Oct 2012 18:09:19 +0200 -Subject: [PATCH 048/131] tests: make t6003-dm-hide work reliably on F17 - -* tests/t6003-dm-hide.sh: Adjust to work reliably on Fedora 17. ---- - tests/t6003-dm-hide.sh | 27 +++++++++++++++++---------- - 1 file changed, 17 insertions(+), 10 deletions(-) - -diff --git a/tests/t6003-dm-hide.sh b/tests/t6003-dm-hide.sh -index 3cfdc43..59baae9 100644 ---- a/tests/t6003-dm-hide.sh -+++ b/tests/t6003-dm-hide.sh -@@ -19,7 +19,6 @@ - . "${srcdir=.}/init.sh"; path_prepend_ ../parted - - require_root_ --lvm_init_root_dir_ - - test "x$ENABLE_DEVICE_MAPPER" = xyes \ - || skip_ "no device-mapper support" -@@ -32,7 +31,10 @@ d1= - f1= - dev= - cleanup_fn_() { -- dmsetup remove $linear_ -+ # Insist. Sometimes the initial removal fails (race?). -+ # When that happens, a second removal appears to be sufficient. -+ dmsetup remove $linear_ || dmsetup remove $linear_ -+ - test -n "$d1" && losetup -d "$d1" - rm -f "$f1" - } -@@ -41,20 +43,25 @@ f1=$(pwd)/1; d1=$(loop_setup_ "$f1") \ - || fail=1 - - # setup: create a mapping --echo "0 2048 linear $d1 0" | dmsetup create $linear_ || fail=1 --dev="$DM_DEV_DIR/mapper/$linear_" -- --# device should not show up -+echo 0 2048 linear $d1 0 | dmsetup create $linear_ || fail=1 -+dev=/dev/mapper/$linear_ - -+# No "DMRAID-" UUID prefix, hence the device should not show up. - parted -l >out 2>&1 --! grep $linear_ out || fail=1 -+grep "^Disk $dev:" out && fail=1 - -+# Unless we perform both dmsetup-remove *and* losetup -d, -+# the following dmsetup-create would fail with EBUSY. - dmsetup remove $linear_ --echo "0 2048 linear $d1 0" | dmsetup create $linear_ -u "DMRAID-fake" || fail=1 -+losetup -d "$d1" || fail=1 -+# Reopen (or get new) loop device. -+d1=$(loop_setup_ "$f1") || fail=1 - --# device should now show up -+# This time, use a fake UUID. -+echo 0 2048 linear $d1 0 | dmsetup create $linear_ -u "DMRAID-fake-$$" || fail=1 - -+# Thus, the device should now show up. - parted -l >out 2>&1 --grep $linear_ out || fail=1 -+grep "^Disk $dev:" out || fail=1 - - Exit $fail --- -1.9.3 - diff --git a/0049-doc-1MiB-alignment-is-not-enough-for-cheap-flash-dri.patch b/0049-doc-1MiB-alignment-is-not-enough-for-cheap-flash-dri.patch deleted file mode 100644 index 107ac7e..0000000 --- a/0049-doc-1MiB-alignment-is-not-enough-for-cheap-flash-dri.patch +++ /dev/null @@ -1,77 +0,0 @@ -From 21be64fc6ef60a1e9dc7bc352131be58cc59d61d Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 2 Jan 2013 12:52:14 +0100 -Subject: [PATCH 049/131] doc: 1MiB-alignment is not enough for cheap flash - drives - -* doc/parted.texi: Add an example that aligns to 4GiB, and -reference Arnd Bergman's LWN article. ---- - doc/parted.texi | 39 ++++++++++++++++++++++++++++++++++----- - 1 file changed, 34 insertions(+), 5 deletions(-) - -diff --git a/doc/parted.texi b/doc/parted.texi -index b8db19d..008c383 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -14,7 +14,7 @@ and manipulating partition tables. - @ifnottex @c texi2pdf don't understand copying and insertcopying ??? - @c modifications must also be done in the titlepage - @copying --Copyright @copyright{} 1999-2012 Free Software Foundation, Inc. -+Copyright @copyright{} 1999-2013 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -@@ -577,15 +577,44 @@ partition table. - @item ufs - @end itemize - --Example: -+For example, the following creates a logical partition that will contain -+an ext2 file system. The partition will start at the beginning of the disk, -+and end 692.1 megabytes into the disk. - - @example - (parted) @kbd{mkpart logical 0.0 692.1} - @end example - --Create a logical partition that will contain an ext2 file system. The --partition will start at the beginning of the disk, and end 692.1 --megabytes into the disk. -+Now, we will show how to partition a low-end flash -+device (``low-end'', as of 2011/2012). -+For such devices, you should use 4MiB-aligned partitions@footnote{ -+Cheap flash drives will be with us for a long time to -+come, and, for them, 1MiB alignment is not enough. -+Use at least 4MiB-aligned partitions. -+For details, see Arnd Bergman's article, -+@uref{http://http://lwn.net/Articles/428584/} and its many comments.}. -+This command creates a tiny place-holder partition at the beginning, and -+then uses all remaining space to create the partition you'll actually use: -+ -+@example -+$ @kbd{parted -s /dev/sdX -- mklabel msdos \} -+@kbd{ mkpart primary fat32 64s 4MiB \} -+@kbd{ mkpart primary fat32 4MiB -1s} -+@end example -+ -+Note the use of @samp{--}, to prevent the following @samp{-1s} last-sector -+indicator from being interpreted as an invalid command-line option. -+The above creates two empty partitions. The first is unaligned and tiny, -+with length less than 4MiB. -+The second partition starts precisely at the 4MiB mark -+and extends to the end of the device. -+ -+The next step is typically to create a file system in the second partition: -+ -+@example -+$ @kbd{mkfs.vfat /dev/sdX2} -+@end example -+ - - @end deffn - --- -1.9.3 - diff --git a/0050-build-update-gnulib-submodule-to-latest.patch b/0050-build-update-gnulib-submodule-to-latest.patch deleted file mode 100644 index cdd9bda..0000000 --- a/0050-build-update-gnulib-submodule-to-latest.patch +++ /dev/null @@ -1,19 +0,0 @@ -From 960eda93fc53ea18e8e98109a00661ac5e8a88f8 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 6 Jan 2013 11:06:23 +0100 -Subject: [PATCH 050/131] build: update gnulib submodule to latest - ---- - gnulib | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/gnulib b/gnulib -index e1abd50..164ebfe 160000 ---- a/gnulib -+++ b/gnulib -@@ -1 +1 @@ --Subproject commit e1abd50b01d6bd61bd0c996ca17378cd569c0aa1 -+Subproject commit 164ebfe612d8460c15d7acf1927faef6943571b6 --- -1.9.3 - diff --git a/0051-maint-update-all-copyright-year-number-ranges.patch b/0051-maint-update-all-copyright-year-number-ranges.patch deleted file mode 100644 index 4156780..0000000 --- a/0051-maint-update-all-copyright-year-number-ranges.patch +++ /dev/null @@ -1,2870 +0,0 @@ -From ab9aecfc64b5a7f6ad70ea93bf76c007614220fd Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 6 Jan 2013 11:08:39 +0100 -Subject: [PATCH 051/131] maint: update all copyright year number ranges - -Run "make update-copyright". ---- - HACKING | 2 +- - NEWS | 2 +- - README-hacking | 2 +- - bootstrap | 2 +- - bootstrap.conf | 2 +- - cfg.mk | 2 +- - configure.ac | 2 +- - debug/test/HOWTO | 2 +- - doc/gendocs.sh | 2 +- - doc/parted-pt_BR.texi | 2 +- - include/parted/constraint.in.h | 2 +- - include/parted/crc32.in.h | 2 +- - include/parted/debug.in.h | 2 +- - include/parted/device.in.h | 2 +- - include/parted/disk.in.h | 2 +- - include/parted/endian.in.h | 2 +- - include/parted/exception.in.h | 2 +- - include/parted/filesys.in.h | 2 +- - include/parted/geom.in.h | 2 +- - include/parted/natmath.in.h | 2 +- - include/parted/parted.in.h | 2 +- - include/parted/timer.in.h | 2 +- - include/parted/unit.in.h | 2 +- - libparted/Makefile.am | 2 +- - libparted/arch/beos.c | 2 +- - libparted/arch/gnu.c | 2 +- - libparted/arch/linux.c | 2 +- - libparted/arch/linux.h | 2 +- - libparted/architecture.c | 2 +- - libparted/architecture.h | 2 +- - libparted/cs/constraint.c | 2 +- - libparted/cs/geom.c | 2 +- - libparted/cs/natmath.c | 2 +- - libparted/debug.c | 2 +- - libparted/disk.c | 2 +- - libparted/exception.c | 2 +- - libparted/filesys.c | 2 +- - libparted/fs/Makefile.am | 2 +- - libparted/fs/amiga/a-interface.c | 2 +- - libparted/fs/amiga/affs.c | 2 +- - libparted/fs/amiga/affs.h | 2 +- - libparted/fs/amiga/amiga.c | 2 +- - libparted/fs/amiga/amiga.h | 2 +- - libparted/fs/amiga/apfs.c | 2 +- - libparted/fs/amiga/apfs.h | 2 +- - libparted/fs/amiga/asfs.c | 2 +- - libparted/fs/amiga/asfs.h | 2 +- - libparted/fs/ext2/ext2.h | 2 +- - libparted/fs/ext2/ext2_fs.h | 2 +- - libparted/fs/ext2/interface.c | 2 +- - libparted/fs/fat/bootsector.c | 2 +- - libparted/fs/fat/bootsector.h | 2 +- - libparted/fs/fat/count.h | 2 +- - libparted/fs/fat/fat.c | 2 +- - libparted/fs/fat/fat.h | 2 +- - libparted/fs/hfs/hfs.c | 2 +- - libparted/fs/hfs/hfs.h | 2 +- - libparted/fs/hfs/probe.c | 2 +- - libparted/fs/hfs/probe.h | 2 +- - libparted/fs/jfs/jfs.c | 2 +- - libparted/fs/linux_swap/linux_swap.c | 2 +- - libparted/fs/nilfs2/nilfs2.c | 2 +- - libparted/fs/ntfs/ntfs.c | 2 +- - libparted/fs/r/fat/bootsector.c | 2 +- - libparted/fs/r/fat/bootsector.h | 2 +- - libparted/fs/r/fat/calc.c | 2 +- - libparted/fs/r/fat/calc.h | 2 +- - libparted/fs/r/fat/clstdup.c | 2 +- - libparted/fs/r/fat/clstdup.h | 2 +- - libparted/fs/r/fat/context.c | 2 +- - libparted/fs/r/fat/context.h | 2 +- - libparted/fs/r/fat/count.c | 2 +- - libparted/fs/r/fat/count.h | 2 +- - libparted/fs/r/fat/fat.c | 2 +- - libparted/fs/r/fat/fat.h | 2 +- - libparted/fs/r/fat/fatio.c | 2 +- - libparted/fs/r/fat/fatio.h | 2 +- - libparted/fs/r/fat/resize.c | 2 +- - libparted/fs/r/fat/table.c | 2 +- - libparted/fs/r/fat/table.h | 2 +- - libparted/fs/r/fat/traverse.c | 2 +- - libparted/fs/r/fat/traverse.h | 2 +- - libparted/fs/r/filesys.c | 2 +- - libparted/fs/r/hfs/advfs.c | 2 +- - libparted/fs/r/hfs/advfs.h | 2 +- - libparted/fs/r/hfs/advfs_plus.c | 2 +- - libparted/fs/r/hfs/advfs_plus.h | 2 +- - libparted/fs/r/hfs/cache.c | 2 +- - libparted/fs/r/hfs/cache.h | 2 +- - libparted/fs/r/hfs/file.c | 2 +- - libparted/fs/r/hfs/file.h | 2 +- - libparted/fs/r/hfs/file_plus.c | 2 +- - libparted/fs/r/hfs/file_plus.h | 2 +- - libparted/fs/r/hfs/hfs.c | 2 +- - libparted/fs/r/hfs/hfs.h | 2 +- - libparted/fs/r/hfs/journal.c | 2 +- - libparted/fs/r/hfs/journal.h | 2 +- - libparted/fs/r/hfs/probe.c | 2 +- - libparted/fs/r/hfs/probe.h | 2 +- - libparted/fs/r/hfs/reloc.c | 2 +- - libparted/fs/r/hfs/reloc.h | 2 +- - libparted/fs/r/hfs/reloc_plus.c | 2 +- - libparted/fs/r/hfs/reloc_plus.h | 2 +- - libparted/fs/reiserfs/reiserfs.c | 2 +- - libparted/fs/reiserfs/reiserfs.h | 2 +- - libparted/fs/ufs/ufs.c | 2 +- - libparted/fs/xfs/xfs.c | 2 +- - libparted/labels/Makefile.am | 2 +- - libparted/labels/aix.c | 2 +- - libparted/labels/bsd.c | 2 +- - libparted/labels/dasd.c | 2 +- - libparted/labels/dos.c | 2 +- - libparted/labels/dvh.c | 2 +- - libparted/labels/loop.c | 2 +- - libparted/labels/mac.c | 2 +- - libparted/labels/misc.h | 2 +- - libparted/labels/pc98.c | 2 +- - libparted/labels/pt-tools.c | 2 +- - libparted/labels/pt-tools.h | 2 +- - libparted/labels/rdb.c | 2 +- - libparted/labels/sun.c | 2 +- - libparted/libparted.c | 2 +- - libparted/mbr.s | 2 +- - libparted/tests/Makefile.am | 2 +- - libparted/tests/t1000-label.sh | 2 +- - libparted/tests/t2000-disk.sh | 2 +- - libparted/tests/t2100-zerolen.sh | 2 +- - libparted/tests/t3000-symlink.sh | 2 +- - libparted/timer.c | 2 +- - libparted/unit.c | 2 +- - m4/o-direct.m4 | 2 +- - parted/command.c | 2 +- - parted/command.h | 2 +- - parted/parted.c | 2 +- - parted/strlist.c | 2 +- - parted/strlist.h | 2 +- - parted/table.c | 2 +- - parted/table.h | 2 +- - parted/ui.c | 2 +- - parted/ui.h | 2 +- - partprobe/partprobe.c | 2 +- - po/POTFILES.in | 2 +- - scripts/extract_symvers | 2 +- - scripts/update-po | 2 +- - tests/help-version.sh | 2 +- - tests/init.sh | 2 +- - tests/t0000-basic.sh | 2 +- - tests/t0001-tiny.sh | 2 +- - tests/t0010-script-no-ctrl-chars.sh | 2 +- - tests/t0100-print.sh | 2 +- - tests/t0101-print-empty.sh | 2 +- - tests/t0200-gpt.sh | 2 +- - tests/t0201-gpt.sh | 2 +- - tests/t0202-gpt-pmbr.sh | 2 +- - tests/t0203-gpt-create-on-min-sized-device.sh | 2 +- - tests/t0203-gpt-shortened-device-primary-valid.sh | 2 +- - tests/t0203-gpt-tiny-device-abort.sh | 2 +- - tests/t0205-gpt-list-clobbers-pmbr.sh | 2 +- - tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh | 2 +- - tests/t0207-IEC-binary-notation.sh | 2 +- - tests/t0208-mkpart-end-in-IEC.sh | 2 +- - tests/t0209-gpt-pmbr_boot.sh | 2 +- - tests/t0210-gpt-resized-partition-entry-array.sh | 2 +- - tests/t0211-gpt-rewrite-header.sh | 2 +- - tests/t0212-gpt-many-partitions.sh | 2 +- - tests/t0220-gpt-msftres.sh | 2 +- - tests/t0250-gpt.sh | 2 +- - tests/t0280-gpt-corrupt.sh | 2 +- - tests/t0300-dos-on-gpt.sh | 2 +- - tests/t0301-overwrite-gpt-pmbr.sh | 2 +- - tests/t0350-mac-PT-increases-sector-size.sh | 2 +- - tests/t0400-loop-clobber-infloop.sh | 2 +- - tests/t0500-dup-clobber.sh | 2 +- - tests/t0501-duplicate.sh | 2 +- - tests/t1100-busy-label.sh | 2 +- - tests/t1101-busy-partition.sh | 2 +- - tests/t1700-probe-fs.sh | 2 +- - tests/t2200-dos-label-recog.sh | 2 +- - tests/t2201-pc98-label-recog.sh | 2 +- - tests/t2300-dos-label-extended-bootcode.sh | 2 +- - tests/t2310-dos-extended-2-sector-min-offset.sh | 2 +- - tests/t2400-dos-hfs-partition-type.sh | 2 +- - tests/t2500-probe-corrupt-hfs.sh | 2 +- - tests/t3000-resize-fs.sh | 2 +- - tests/t3200-type-change.sh | 2 +- - tests/t3300-palo-prep.sh | 2 +- - tests/t3310-flags.sh | 2 +- - tests/t3400-whole-disk-FAT-partition.sh | 2 +- - tests/t4000-sun-raid-type.sh | 2 +- - tests/t4001-sun-vtoc.sh | 2 +- - tests/t4100-dvh-partition-limits.sh | 2 +- - tests/t4100-msdos-partition-limits.sh | 2 +- - tests/t4100-msdos-starting-sector.sh | 2 +- - tests/t4200-partprobe.sh | 2 +- - tests/t4300-nilfs2-tiny.sh | 2 +- - tests/t5000-tags.sh | 2 +- - tests/t6000-dm.sh | 2 +- - tests/t6001-psep.sh | 2 +- - tests/t6002-dm-busy.sh | 2 +- - tests/t6003-dm-hide.sh | 2 +- - tests/t6100-mdraid-partitions.sh | 2 +- - tests/t7000-scripting.sh | 2 +- - tests/t8000-loop.sh | 2 +- - tests/t8001-loop-blkpg.sh | 2 +- - tests/t9010-big-sector.sh | 2 +- - tests/t9020-alignment.sh | 2 +- - tests/t9021-maxima.sh | 2 +- - tests/t9022-one-unit-snap.sh | 2 +- - tests/t9023-value-lt-one.sh | 2 +- - tests/t9030-align-check.sh | 2 +- - tests/t9040-many-partitions.sh | 2 +- - tests/t9041-undetected-in-use-16th-partition.sh | 2 +- - tests/t9042-dos-partition-limit.sh | 2 +- - tests/t9050-partition-table-types.sh | 2 +- - 214 files changed, 214 insertions(+), 214 deletions(-) - -diff --git a/HACKING b/HACKING -index 297cbd8..b8e501c 100644 ---- a/HACKING -+++ b/HACKING -@@ -581,7 +581,7 @@ Then just open the index.html file (in the generated lcov-html directory) - in your favorite web browser. - - ======================================================================== --Copyright (C) 2009-2012 Free Software Foundation, Inc. -+Copyright (C) 2009-2013 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -diff --git a/NEWS b/NEWS -index 89541fd..98f7c6e 100644 ---- a/NEWS -+++ b/NEWS -@@ -744,7 +744,7 @@ GNU parted NEWS -*- outline -*- - - ======================================================================== - --Copyright (C) 2001-2012 Free Software Foundation, Inc. -+Copyright (C) 2001-2013 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -diff --git a/README-hacking b/README-hacking -index 4aaa222..5aa9ef3 100644 ---- a/README-hacking -+++ b/README-hacking -@@ -69,7 +69,7 @@ Enjoy! - - ----- - --Copyright (C) 2002-2012 Free Software Foundation, Inc. -+Copyright (C) 2002-2013 Free Software Foundation, Inc. - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/bootstrap b/bootstrap -index e3e270b..48181c9 100755 ---- a/bootstrap -+++ b/bootstrap -@@ -4,7 +4,7 @@ scriptversion=2012-07-19.14; # UTC - - # Bootstrap this package from checked-out sources. - --# Copyright (C) 2003-2012 Free Software Foundation, Inc. -+# Copyright (C) 2003-2013 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/bootstrap.conf b/bootstrap.conf -index 7f4ee53..f6f4ff2 100644 ---- a/bootstrap.conf -+++ b/bootstrap.conf -@@ -1,6 +1,6 @@ - # Bootstrap configuration. - --# Copyright (C) 2006-2012 Free Software Foundation, Inc. -+# Copyright (C) 2006-2013 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/cfg.mk b/cfg.mk -index 3d3014c..2590a38 100644 ---- a/cfg.mk -+++ b/cfg.mk -@@ -1,5 +1,5 @@ - # Customize maint.mk -*- makefile -*- --# Copyright (C) 2003-2012 Free Software Foundation, Inc. -+# Copyright (C) 2003-2013 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/configure.ac b/configure.ac -index 417f325..fef0b53 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -1,5 +1,5 @@ - dnl GNU Parted - a library and front end for manipulation hard disk partitions --dnl Copyright (C) 1998-2002, 2005-2012 Free Software Foundation, Inc. -+dnl Copyright (C) 1998-2002, 2005-2013 Free Software Foundation, Inc. - dnl - dnl This file may be modified and/or distributed without restriction. - -diff --git a/debug/test/HOWTO b/debug/test/HOWTO -index 92d59f2..f611e4f 100644 ---- a/debug/test/HOWTO -+++ b/debug/test/HOWTO -@@ -4,7 +4,7 @@ - - by Andrew Clausen - -- Copyright (C) 2002, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2002, 2009-2013 Free Software Foundation, Inc. - This document may be distributed and/or modified - without restriction - -diff --git a/doc/gendocs.sh b/doc/gendocs.sh -index 0b69819..1d2f9be 100755 ---- a/doc/gendocs.sh -+++ b/doc/gendocs.sh -@@ -3,7 +3,7 @@ - # mentioned in maintain.texi. See the help message below for usage details. - # $Id: gendocs.sh,v 1.16 2005/05/15 00:00:08 karl Exp $ - # --# Copyright (C) 2003-2007, 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2003-2007, 2009-2013 Free Software Foundation, Inc. - # - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/doc/parted-pt_BR.texi b/doc/parted-pt_BR.texi -index 8878f83..8858ab5 100644 ---- a/doc/parted-pt_BR.texi -+++ b/doc/parted-pt_BR.texi -@@ -22,7 +22,7 @@ - This file documents the use of GNU Parted, a program for creating, - resising, checking and copy partitions, and file systems on them. - --Copyright 1999-2002, 2009-2012 Free Software Foundation, Inc. -+Copyright 1999-2002, 2009-2013 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -diff --git a/include/parted/constraint.in.h b/include/parted/constraint.in.h -index 5f42fa0..4f7855b 100644 ---- a/include/parted/constraint.in.h -+++ b/include/parted/constraint.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/crc32.in.h b/include/parted/crc32.in.h -index 74941f6..af8de0a 100644 ---- a/include/parted/crc32.in.h -+++ b/include/parted/crc32.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - crc32.h - -diff --git a/include/parted/debug.in.h b/include/parted/debug.in.h -index 09b47ab..07c1257 100644 ---- a/include/parted/debug.in.h -+++ b/include/parted/debug.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2000, 2002, 2007, 2009-2012 Free Software Foundation, -+ Copyright (C) 1998-2000, 2002, 2007, 2009-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/device.in.h b/include/parted/device.in.h -index a3d1737..7c06a66 100644 ---- a/include/parted/device.in.h -+++ b/include/parted/device.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2001, 2005, 2007-2008, 2011-2012 Free Software -+ Copyright (C) 1998-2001, 2005, 2007-2008, 2011-2013 Free Software - Foundation, Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/disk.in.h b/include/parted/disk.in.h -index a34e11e..aa905c5 100644 ---- a/include/parted/disk.in.h -+++ b/include/parted/disk.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2002, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2002, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/endian.in.h b/include/parted/endian.in.h -index 0e7c923..381059f 100644 ---- a/include/parted/endian.in.h -+++ b/include/parted/endian.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2002, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2002, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/exception.in.h b/include/parted/exception.in.h -index dd302b8..ef96280 100644 ---- a/include/parted/exception.in.h -+++ b/include/parted/exception.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/filesys.in.h b/include/parted/filesys.in.h -index c0f72f4..d9f626b 100644 ---- a/include/parted/filesys.in.h -+++ b/include/parted/filesys.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2006-2007, 2009-2012 Free Software Foundation, -+ Copyright (C) 1999-2001, 2006-2007, 2009-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/geom.in.h b/include/parted/geom.in.h -index 15ad017..9adeee8 100644 ---- a/include/parted/geom.in.h -+++ b/include/parted/geom.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2001, 2005, 2007, 2009-2012 Free Software Foundation, -+ Copyright (C) 1998-2001, 2005, 2007, 2009-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/natmath.in.h b/include/parted/natmath.in.h -index e1d09eb..284db26 100644 ---- a/include/parted/natmath.in.h -+++ b/include/parted/natmath.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/parted.in.h b/include/parted/parted.in.h -index 856b7aa..9a4f69c 100644 ---- a/include/parted/parted.in.h -+++ b/include/parted/parted.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/timer.in.h b/include/parted/timer.in.h -index 7f25b2e..c7c42eb 100644 ---- a/include/parted/timer.in.h -+++ b/include/parted/timer.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001-2002, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/unit.in.h b/include/parted/unit.in.h -index 584a0c4..119cfe3 100644 ---- a/include/parted/unit.in.h -+++ b/include/parted/unit.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/Makefile.am b/libparted/Makefile.am -index bdc7976..bbb43ae 100644 ---- a/libparted/Makefile.am -+++ b/libparted/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/arch/beos.c b/libparted/arch/beos.c -index edd3fd9..6a8a5ae 100644 ---- a/libparted/arch/beos.c -+++ b/libparted/arch/beos.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2006-2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2006-2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/arch/gnu.c b/libparted/arch/gnu.c -index 62d3fe4..21d1f35 100644 ---- a/libparted/arch/gnu.c -+++ b/libparted/arch/gnu.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2005, 2007, 2009-2012 Free Software Foundation, -+ Copyright (C) 1999-2001, 2005, 2007, 2009-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 083591f..2bb8774 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/arch/linux.h b/libparted/arch/linux.h -index cf6a6d8..865134a 100644 ---- a/libparted/arch/linux.h -+++ b/libparted/arch/linux.h -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/architecture.c b/libparted/architecture.c -index 3b033a1..b339dc4 100644 ---- a/libparted/architecture.c -+++ b/libparted/architecture.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/architecture.h b/libparted/architecture.h -index 5fe88e7..98345dd 100644 ---- a/libparted/architecture.h -+++ b/libparted/architecture.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/cs/constraint.c b/libparted/cs/constraint.c -index 4b28d63..21e80a7 100644 ---- a/libparted/cs/constraint.c -+++ b/libparted/cs/constraint.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/cs/geom.c b/libparted/cs/geom.c -index 3eea9e9..65c10c5 100644 ---- a/libparted/cs/geom.c -+++ b/libparted/cs/geom.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2005, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2005, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/cs/natmath.c b/libparted/cs/natmath.c -index 2d5e2bf..4ebcb5a 100644 ---- a/libparted/cs/natmath.c -+++ b/libparted/cs/natmath.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/debug.c b/libparted/debug.c -index ceca0c5..bbc84dc 100644 ---- a/libparted/debug.c -+++ b/libparted/debug.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/disk.c b/libparted/disk.c -index d283674..d3cd5bb 100644 ---- a/libparted/disk.c -+++ b/libparted/disk.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2003, 2005, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2003, 2005, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/exception.c b/libparted/exception.c -index a71df0e..f4c771d 100644 ---- a/libparted/exception.c -+++ b/libparted/exception.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/filesys.c b/libparted/filesys.c -index fd85e5d..1870808 100644 ---- a/libparted/filesys.c -+++ b/libparted/filesys.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/Makefile.am b/libparted/fs/Makefile.am -index 064f11a..aac03cc 100644 ---- a/libparted/fs/Makefile.am -+++ b/libparted/fs/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/fs/amiga/a-interface.c b/libparted/fs/amiga/a-interface.c -index a084266..f8dd131 100644 ---- a/libparted/fs/amiga/a-interface.c -+++ b/libparted/fs/amiga/a-interface.c -@@ -1,6 +1,6 @@ - /* - interface.c -- parted support amiga file systems -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/affs.c b/libparted/fs/amiga/affs.c -index fefead3..6b7624d 100644 ---- a/libparted/fs/amiga/affs.c -+++ b/libparted/fs/amiga/affs.c -@@ -1,6 +1,6 @@ - /* - affs.c -- parted support for affs file systems -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/affs.h b/libparted/fs/amiga/affs.h -index 7223faf..5c8cc9c 100644 ---- a/libparted/fs/amiga/affs.h -+++ b/libparted/fs/amiga/affs.h -@@ -1,7 +1,7 @@ - - /* - affs.h -- parted suppoer for affs filesystems header files -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/amiga.c b/libparted/fs/amiga/amiga.c -index 7b8462e..31e1a3b 100644 ---- a/libparted/fs/amiga/amiga.c -+++ b/libparted/fs/amiga/amiga.c -@@ -1,6 +1,6 @@ - /* - libparted/fs_amiga - amiga file system support. -- Copyright (C) 2000-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/amiga.h b/libparted/fs/amiga/amiga.h -index 9debd30..746030e 100644 ---- a/libparted/fs/amiga/amiga.h -+++ b/libparted/fs/amiga/amiga.h -@@ -1,6 +1,6 @@ - /* - util.h -- amiga partition table headers. -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/apfs.c b/libparted/fs/amiga/apfs.c -index 9d2757b..9f9e6e0 100644 ---- a/libparted/fs/amiga/apfs.c -+++ b/libparted/fs/amiga/apfs.c -@@ -1,6 +1,6 @@ - /* - apfs.c -- parted support for apfs file systems -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/apfs.h b/libparted/fs/amiga/apfs.h -index ecc1a02..a611db5 100644 ---- a/libparted/fs/amiga/apfs.h -+++ b/libparted/fs/amiga/apfs.h -@@ -1,6 +1,6 @@ - /* - apfs.h -- parted support for apfs file systems header files -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/asfs.c b/libparted/fs/amiga/asfs.c -index 3a9dce7..f7b4ed0 100644 ---- a/libparted/fs/amiga/asfs.c -+++ b/libparted/fs/amiga/asfs.c -@@ -1,6 +1,6 @@ - /* - asfs.c -- parted asfs filesystem support -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/asfs.h b/libparted/fs/amiga/asfs.h -index 1f5e56c..9b1fb78 100644 ---- a/libparted/fs/amiga/asfs.h -+++ b/libparted/fs/amiga/asfs.h -@@ -1,6 +1,6 @@ - /* - asfs.h -- parted asfs filesystem support header files -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ext2/ext2.h b/libparted/fs/ext2/ext2.h -index ee0b121..4559d6a 100644 ---- a/libparted/fs/ext2/ext2.h -+++ b/libparted/fs/ext2/ext2.h -@@ -1,6 +1,6 @@ - /* - ext2.h -- ext2 header -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ext2/ext2_fs.h b/libparted/fs/ext2/ext2_fs.h -index fe2a396..b2cd3b2 100644 ---- a/libparted/fs/ext2/ext2_fs.h -+++ b/libparted/fs/ext2/ext2_fs.h -@@ -15,7 +15,7 @@ - - /* - * EXT2_*_*() convienience macros added by Andrew Clausen -- * Copyright (C) 2000, 2009-2012 Free Software Foundation, Inc. -+ * Copyright (C) 2000, 2009-2013 Free Software Foundation, Inc. - */ - - #ifndef _EXT2_FS_H -diff --git a/libparted/fs/ext2/interface.c b/libparted/fs/ext2/interface.c -index 1159375..97220b7 100644 ---- a/libparted/fs/ext2/interface.c -+++ b/libparted/fs/ext2/interface.c -@@ -1,6 +1,6 @@ - /* - interface.c -- parted binding glue to libext2resize -- Copyright (C) 1998-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/bootsector.c b/libparted/fs/fat/bootsector.c -index c43940f..d4f8dc4 100644 ---- a/libparted/fs/fat/bootsector.c -+++ b/libparted/fs/fat/bootsector.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2012 Free Software -+ Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2013 Free Software - Foundation, Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/fat/bootsector.h b/libparted/fs/fat/bootsector.h -index 2b51cd1..3f84742 100644 ---- a/libparted/fs/fat/bootsector.h -+++ b/libparted/fs/fat/bootsector.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/count.h b/libparted/fs/fat/count.h -index a1c8438..2c675a3 100644 ---- a/libparted/fs/fat/count.h -+++ b/libparted/fs/fat/count.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/fat.c b/libparted/fs/fat/fat.c -index 62e8790..95cbc8d 100644 ---- a/libparted/fs/fat/fat.c -+++ b/libparted/fs/fat/fat.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/fat.h b/libparted/fs/fat/fat.h -index b1b96ba..437a020 100644 ---- a/libparted/fs/fat/fat.h -+++ b/libparted/fs/fat/fat.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/hfs/hfs.c b/libparted/fs/hfs/hfs.c -index a03cf48..40c8173 100644 ---- a/libparted/fs/hfs/hfs.c -+++ b/libparted/fs/hfs/hfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2003-2005, 2007, 2009-2012 Free Software Foundation, -+ Copyright (C) 2000, 2003-2005, 2007, 2009-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/hfs/hfs.h b/libparted/fs/hfs/hfs.h -index 4e15e79..c3c79d8 100644 ---- a/libparted/fs/hfs/hfs.h -+++ b/libparted/fs/hfs/hfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2003-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2003-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/hfs/probe.c b/libparted/fs/hfs/probe.c -index 71b8342..ad79a64 100644 ---- a/libparted/fs/hfs/probe.c -+++ b/libparted/fs/hfs/probe.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/hfs/probe.h b/libparted/fs/hfs/probe.h -index 0b4a01f..0dc036a 100644 ---- a/libparted/fs/hfs/probe.h -+++ b/libparted/fs/hfs/probe.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/jfs/jfs.c b/libparted/fs/jfs/jfs.c -index 0959d96..803c241 100644 ---- a/libparted/fs/jfs/jfs.c -+++ b/libparted/fs/jfs/jfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/linux_swap/linux_swap.c b/libparted/fs/linux_swap/linux_swap.c -index 77b97db..bbc034d 100644 ---- a/libparted/fs/linux_swap/linux_swap.c -+++ b/libparted/fs/linux_swap/linux_swap.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2002, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2002, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/nilfs2/nilfs2.c b/libparted/fs/nilfs2/nilfs2.c -index a184a36..bb0a84e 100644 ---- a/libparted/fs/nilfs2/nilfs2.c -+++ b/libparted/fs/nilfs2/nilfs2.c -@@ -3,7 +3,7 @@ - * - * Written by Jiro SEKIBA - * -- * Copyright (C) 2011-2012 Free Software Foundation, Inc. -+ * Copyright (C) 2011-2013 Free Software Foundation, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ntfs/ntfs.c b/libparted/fs/ntfs/ntfs.c -index 4c92d9e..05d7f36 100644 ---- a/libparted/fs/ntfs/ntfs.c -+++ b/libparted/fs/ntfs/ntfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/bootsector.c b/libparted/fs/r/fat/bootsector.c -index 8c7a8c3..07b39cf 100644 ---- a/libparted/fs/r/fat/bootsector.c -+++ b/libparted/fs/r/fat/bootsector.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2012 Free Software -+ Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2013 Free Software - Foundation, Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/r/fat/bootsector.h b/libparted/fs/r/fat/bootsector.h -index 4783649..ec367c3 100644 ---- a/libparted/fs/r/fat/bootsector.h -+++ b/libparted/fs/r/fat/bootsector.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/calc.c b/libparted/fs/r/fat/calc.c -index d8f3a98..c4c8dba 100644 ---- a/libparted/fs/r/fat/calc.c -+++ b/libparted/fs/r/fat/calc.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2002, 2007, 2009-2012 Free Software Foundation, -+ Copyright (C) 1998-2000, 2002, 2007, 2009-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/r/fat/calc.h b/libparted/fs/r/fat/calc.h -index 25e36f7..4d80954 100644 ---- a/libparted/fs/r/fat/calc.h -+++ b/libparted/fs/r/fat/calc.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/clstdup.c b/libparted/fs/r/fat/clstdup.c -index 73ac8d6..4acbbc8 100644 ---- a/libparted/fs/r/fat/clstdup.c -+++ b/libparted/fs/r/fat/clstdup.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/clstdup.h b/libparted/fs/r/fat/clstdup.h -index eee55a0..a811c4c 100644 ---- a/libparted/fs/r/fat/clstdup.h -+++ b/libparted/fs/r/fat/clstdup.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/context.c b/libparted/fs/r/fat/context.c -index 2cd933a..7767f14 100644 ---- a/libparted/fs/r/fat/context.c -+++ b/libparted/fs/r/fat/context.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/context.h b/libparted/fs/r/fat/context.h -index 0bd8922..5701b1b 100644 ---- a/libparted/fs/r/fat/context.h -+++ b/libparted/fs/r/fat/context.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/count.c b/libparted/fs/r/fat/count.c -index abd9e71..e551fef 100644 ---- a/libparted/fs/r/fat/count.c -+++ b/libparted/fs/r/fat/count.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/count.h b/libparted/fs/r/fat/count.h -index a1c8438..2c675a3 100644 ---- a/libparted/fs/r/fat/count.h -+++ b/libparted/fs/r/fat/count.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fat.c b/libparted/fs/r/fat/fat.c -index 9d43e21..2ab9279 100644 ---- a/libparted/fs/r/fat/fat.c -+++ b/libparted/fs/r/fat/fat.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fat.h b/libparted/fs/r/fat/fat.h -index e90a81e..d2ac2aa 100644 ---- a/libparted/fs/r/fat/fat.h -+++ b/libparted/fs/r/fat/fat.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fatio.c b/libparted/fs/r/fat/fatio.c -index f0b8724..75dca0c 100644 ---- a/libparted/fs/r/fat/fatio.c -+++ b/libparted/fs/r/fat/fatio.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fatio.h b/libparted/fs/r/fat/fatio.h -index c7c6b26..f23ab01 100644 ---- a/libparted/fs/r/fat/fatio.h -+++ b/libparted/fs/r/fat/fatio.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/resize.c b/libparted/fs/r/fat/resize.c -index 867448f..2b68a8b 100644 ---- a/libparted/fs/r/fat/resize.c -+++ b/libparted/fs/r/fat/resize.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/table.c b/libparted/fs/r/fat/table.c -index 61092bd..974dea8 100644 ---- a/libparted/fs/r/fat/table.c -+++ b/libparted/fs/r/fat/table.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/table.h b/libparted/fs/r/fat/table.h -index d507fea..16180f1 100644 ---- a/libparted/fs/r/fat/table.h -+++ b/libparted/fs/r/fat/table.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/traverse.c b/libparted/fs/r/fat/traverse.c -index a120f4e..623b6a9 100644 ---- a/libparted/fs/r/fat/traverse.c -+++ b/libparted/fs/r/fat/traverse.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2005, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2005, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/traverse.h b/libparted/fs/r/fat/traverse.h -index 1f731b9..95633cb 100644 ---- a/libparted/fs/r/fat/traverse.h -+++ b/libparted/fs/r/fat/traverse.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/filesys.c b/libparted/fs/r/filesys.c -index 7bffea0..4b8b831 100644 ---- a/libparted/fs/r/filesys.c -+++ b/libparted/fs/r/filesys.c -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs.c b/libparted/fs/r/hfs/advfs.c -index 337c449..b5609d6 100644 ---- a/libparted/fs/r/hfs/advfs.c -+++ b/libparted/fs/r/hfs/advfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs.h b/libparted/fs/r/hfs/advfs.h -index 260e432..434d215 100644 ---- a/libparted/fs/r/hfs/advfs.h -+++ b/libparted/fs/r/hfs/advfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs_plus.c b/libparted/fs/r/hfs/advfs_plus.c -index b7f2415..b7a95d1 100644 ---- a/libparted/fs/r/hfs/advfs_plus.c -+++ b/libparted/fs/r/hfs/advfs_plus.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs_plus.h b/libparted/fs/r/hfs/advfs_plus.h -index 974e421..2825c54 100644 ---- a/libparted/fs/r/hfs/advfs_plus.h -+++ b/libparted/fs/r/hfs/advfs_plus.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/cache.c b/libparted/fs/r/hfs/cache.c -index 6c5a7c7..45d8d93 100644 ---- a/libparted/fs/r/hfs/cache.c -+++ b/libparted/fs/r/hfs/cache.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/cache.h b/libparted/fs/r/hfs/cache.h -index afcba62..6196698 100644 ---- a/libparted/fs/r/hfs/cache.h -+++ b/libparted/fs/r/hfs/cache.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file.c b/libparted/fs/r/hfs/file.c -index ab6344d..70ad3ab 100644 ---- a/libparted/fs/r/hfs/file.c -+++ b/libparted/fs/r/hfs/file.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file.h b/libparted/fs/r/hfs/file.h -index f778745..f8a6594 100644 ---- a/libparted/fs/r/hfs/file.h -+++ b/libparted/fs/r/hfs/file.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file_plus.c b/libparted/fs/r/hfs/file_plus.c -index 9a7c905..2a271da 100644 ---- a/libparted/fs/r/hfs/file_plus.c -+++ b/libparted/fs/r/hfs/file_plus.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file_plus.h b/libparted/fs/r/hfs/file_plus.h -index 19aedf4..0d0c910 100644 ---- a/libparted/fs/r/hfs/file_plus.h -+++ b/libparted/fs/r/hfs/file_plus.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/hfs.c b/libparted/fs/r/hfs/hfs.c -index f7f98f4..26c789a 100644 ---- a/libparted/fs/r/hfs/hfs.c -+++ b/libparted/fs/r/hfs/hfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2003-2005, 2007, 2009-2012 Free Software Foundation, -+ Copyright (C) 2000, 2003-2005, 2007, 2009-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/r/hfs/hfs.h b/libparted/fs/r/hfs/hfs.h -index 4e15e79..c3c79d8 100644 ---- a/libparted/fs/r/hfs/hfs.h -+++ b/libparted/fs/r/hfs/hfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2003-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2003-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/journal.c b/libparted/fs/r/hfs/journal.c -index 80eb6d0..54a065d 100644 ---- a/libparted/fs/r/hfs/journal.c -+++ b/libparted/fs/r/hfs/journal.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/journal.h b/libparted/fs/r/hfs/journal.h -index b130874..12551c4 100644 ---- a/libparted/fs/r/hfs/journal.h -+++ b/libparted/fs/r/hfs/journal.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/probe.c b/libparted/fs/r/hfs/probe.c -index 376a821..76b21dc 100644 ---- a/libparted/fs/r/hfs/probe.c -+++ b/libparted/fs/r/hfs/probe.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/probe.h b/libparted/fs/r/hfs/probe.h -index ba754bb..c779843 100644 ---- a/libparted/fs/r/hfs/probe.h -+++ b/libparted/fs/r/hfs/probe.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc.c b/libparted/fs/r/hfs/reloc.c -index e3b6b40..abc6b1b 100644 ---- a/libparted/fs/r/hfs/reloc.c -+++ b/libparted/fs/r/hfs/reloc.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc.h b/libparted/fs/r/hfs/reloc.h -index 294e158..a5fccaf 100644 ---- a/libparted/fs/r/hfs/reloc.h -+++ b/libparted/fs/r/hfs/reloc.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc_plus.c b/libparted/fs/r/hfs/reloc_plus.c -index c566e72..6c2408c 100644 ---- a/libparted/fs/r/hfs/reloc_plus.c -+++ b/libparted/fs/r/hfs/reloc_plus.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc_plus.h b/libparted/fs/r/hfs/reloc_plus.h -index afcd750..dc71478 100644 ---- a/libparted/fs/r/hfs/reloc_plus.h -+++ b/libparted/fs/r/hfs/reloc_plus.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/reiserfs/reiserfs.c b/libparted/fs/reiserfs/reiserfs.c -index 6344152..21d4272 100644 ---- a/libparted/fs/reiserfs/reiserfs.c -+++ b/libparted/fs/reiserfs/reiserfs.c -@@ -1,6 +1,6 @@ - /* - reiserfs.c -- libparted / libreiserfs glue -- Copyright (C) 2001-2002, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/reiserfs/reiserfs.h b/libparted/fs/reiserfs/reiserfs.h -index 464cd1e..f215b0b 100644 ---- a/libparted/fs/reiserfs/reiserfs.h -+++ b/libparted/fs/reiserfs/reiserfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ufs/ufs.c b/libparted/fs/ufs/ufs.c -index d9b059d..b668d7b 100644 ---- a/libparted/fs/ufs/ufs.c -+++ b/libparted/fs/ufs/ufs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/xfs/xfs.c b/libparted/fs/xfs/xfs.c -index b360abe..0062604 100644 ---- a/libparted/fs/xfs/xfs.c -+++ b/libparted/fs/xfs/xfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/Makefile.am b/libparted/labels/Makefile.am -index f4e4d27..281dce1 100644 ---- a/libparted/labels/Makefile.am -+++ b/libparted/labels/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/labels/aix.c b/libparted/labels/aix.c -index 897253e..98de112 100644 ---- a/libparted/labels/aix.c -+++ b/libparted/labels/aix.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/bsd.c b/libparted/labels/bsd.c -index 3970623..79332ab 100644 ---- a/libparted/labels/bsd.c -+++ b/libparted/labels/bsd.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/dasd.c b/libparted/labels/dasd.c -index c8bd267..a769866 100644 ---- a/libparted/labels/dasd.c -+++ b/libparted/labels/dasd.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/dos.c b/libparted/labels/dos.c -index 1d3a867..b8c161f 100644 ---- a/libparted/labels/dos.c -+++ b/libparted/labels/dos.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2004-2005, 2007-2012 Free Software Foundation, -+ Copyright (C) 1999-2001, 2004-2005, 2007-2013 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/labels/dvh.c b/libparted/labels/dvh.c -index f817974..91b9080 100644 ---- a/libparted/labels/dvh.c -+++ b/libparted/labels/dvh.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001-2002, 2005, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2005, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/loop.c b/libparted/labels/loop.c -index e96e9e6..ea8f007 100644 ---- a/libparted/labels/loop.c -+++ b/libparted/labels/loop.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/mac.c b/libparted/labels/mac.c -index 2485187..f26f8e5 100644 ---- a/libparted/labels/mac.c -+++ b/libparted/labels/mac.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2002, 2004, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2002, 2004, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/misc.h b/libparted/labels/misc.h -index cdcc91b..c2ccea1 100644 ---- a/libparted/labels/misc.h -+++ b/libparted/labels/misc.h -@@ -1,7 +1,7 @@ - /* -*- Mode: c; indent-tabs-mode: nil -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/pc98.c b/libparted/labels/pc98.c -index 617acab..ad13c0d 100644 ---- a/libparted/labels/pc98.c -+++ b/libparted/labels/pc98.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/pt-tools.c b/libparted/labels/pt-tools.c -index 2693151..547b27c 100644 ---- a/libparted/labels/pt-tools.c -+++ b/libparted/labels/pt-tools.c -@@ -1,5 +1,5 @@ - /* partition table tools -- Copyright (C) 2008-2012 Free Software Foundation, Inc. -+ Copyright (C) 2008-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/pt-tools.h b/libparted/labels/pt-tools.h -index aa31122..7b5c9f5 100644 ---- a/libparted/labels/pt-tools.h -+++ b/libparted/labels/pt-tools.h -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 2008-2012 Free Software Foundation, Inc. -+ Copyright (C) 2008-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/rdb.c b/libparted/labels/rdb.c -index 8370351..4cf1463 100644 ---- a/libparted/labels/rdb.c -+++ b/libparted/labels/rdb.c -@@ -2,7 +2,7 @@ - - libparted - a library for manipulating disk partitions - disk_amiga.c - libparted module to manipulate amiga RDB partition tables. -- Copyright (C) 2000-2001, 2004, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2004, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/sun.c b/libparted/labels/sun.c -index c7a11b5..245208e 100644 ---- a/libparted/labels/sun.c -+++ b/libparted/labels/sun.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2005, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2005, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/libparted.c b/libparted/libparted.c -index a6d86f0..9923bfa 100644 ---- a/libparted/libparted.c -+++ b/libparted/libparted.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/mbr.s b/libparted/mbr.s -index e30b034..4a1c5dd 100644 ---- a/libparted/mbr.s -+++ b/libparted/mbr.s -@@ -1,5 +1,5 @@ - ; libparted - a library for manipulating disk partitions --; Copyright (C) 1999-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+; Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. - ; - ; This program is free software; you can redistribute it and/or modify - ; it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/Makefile.am b/libparted/tests/Makefile.am -index ec01599..bfa5790 100644 ---- a/libparted/tests/Makefile.am -+++ b/libparted/tests/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/tests/t1000-label.sh b/libparted/tests/t1000-label.sh -index 2134721..afa78dd 100755 ---- a/libparted/tests/t1000-label.sh -+++ b/libparted/tests/t1000-label.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the label unit tests in a directory supporting O_DIRECT - --# Copyright (C) 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/t2000-disk.sh b/libparted/tests/t2000-disk.sh -index 905ef8b..1f058bd 100755 ---- a/libparted/tests/t2000-disk.sh -+++ b/libparted/tests/t2000-disk.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the disk unit tests in a directory supporting O_DIRECT - --# Copyright (C) 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/t2100-zerolen.sh b/libparted/tests/t2100-zerolen.sh -index 6c2d75e..f08c8ad 100755 ---- a/libparted/tests/t2100-zerolen.sh -+++ b/libparted/tests/t2100-zerolen.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the zerolen unit tests in a directory supporting O_DIRECT - --# Copyright (C) 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/t3000-symlink.sh b/libparted/tests/t3000-symlink.sh -index 70abec4..338e44a 100755 ---- a/libparted/tests/t3000-symlink.sh -+++ b/libparted/tests/t3000-symlink.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the /dev/mapper symlink test - --# Copyright (C) 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/timer.c b/libparted/timer.c -index 390c08e..7999c44 100644 ---- a/libparted/timer.c -+++ b/libparted/timer.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/unit.c b/libparted/unit.c -index 66f2b6c..e545985 100644 ---- a/libparted/unit.c -+++ b/libparted/unit.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2005, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2005, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/m4/o-direct.m4 b/m4/o-direct.m4 -index a754bf0..f677d37 100644 ---- a/m4/o-direct.m4 -+++ b/m4/o-direct.m4 -@@ -3,7 +3,7 @@ - # The problem is that on systems supporting O_DIRECT, open with O_DIRECT - # fails for some file system types (e.g., tmpfs on linux-2.6.21). - --# Copyright (C) 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007-2013 Free Software Foundation, Inc. - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, - # with or without modifications, as long as this notice is preserved. -diff --git a/parted/command.c b/parted/command.c -index 63af343..e91c0c6 100644 ---- a/parted/command.c -+++ b/parted/command.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/command.h b/parted/command.h -index b602c24..fed7a23 100644 ---- a/parted/command.h -+++ b/parted/command.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2000, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/parted.c b/parted/parted.c -index 789030a..b20d432 100644 ---- a/parted/parted.c -+++ b/parted/parted.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2003, 2005-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2003, 2005-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/strlist.c b/parted/strlist.c -index 1f90c0e..a7a1b23 100644 ---- a/parted/strlist.c -+++ b/parted/strlist.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/strlist.h b/parted/strlist.h -index 3808818..6df769b 100644 ---- a/parted/strlist.h -+++ b/parted/strlist.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2001, 2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/table.c b/parted/table.c -index 8563e3c..6c08fd1 100644 ---- a/parted/table.c -+++ b/parted/table.c -@@ -3,7 +3,7 @@ - */ - /* - parted - a frontend to libparted -- Copyright (C) 2006-2012 Free Software Foundation, Inc. -+ Copyright (C) 2006-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/table.h b/parted/table.h -index 23120c3..12a115a 100644 ---- a/parted/table.h -+++ b/parted/table.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 2006-2007, 2009-2012 Free Software Foundation, Inc. -+ Copyright (C) 2006-2007, 2009-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/ui.c b/parted/ui.c -index d00c65a..22790bb 100644 ---- a/parted/ui.c -+++ b/parted/ui.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2002, 2006-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2002, 2006-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/ui.h b/parted/ui.h -index 9c8605a..3c6ebc0 100644 ---- a/parted/ui.h -+++ b/parted/ui.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2001, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/partprobe/partprobe.c b/partprobe/partprobe.c -index 0919d3f..4da4fb7 100644 ---- a/partprobe/partprobe.c -+++ b/partprobe/partprobe.c -@@ -1,6 +1,6 @@ - /* - partprobe - informs the OS kernel of partition layout -- Copyright (C) 2001-2002, 2007-2012 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2007-2013 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/po/POTFILES.in b/po/POTFILES.in -index 6eefa26..a09d7e9 100644 ---- a/po/POTFILES.in -+++ b/po/POTFILES.in -@@ -1,5 +1,5 @@ - # libparted --# Copyright (C) 1999-2001, 2006-2012 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2006-2013 Free Software Foundation, Inc. - # This file may be modified and/or copied without restriction. - - # list of files containing translatable strings -diff --git a/scripts/extract_symvers b/scripts/extract_symvers -index e62693d..06b2525 100755 ---- a/scripts/extract_symvers -+++ b/scripts/extract_symvers -@@ -1,6 +1,6 @@ - #!/bin/sh - --# Copyright (C) 2002-2003, 2007, 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2002-2003, 2007, 2009-2013 Free Software Foundation, Inc. - # - # This file is part of the GNU ISO C++ Library. This library is free - # software; you can redistribute it and/or modify it under the -diff --git a/scripts/update-po b/scripts/update-po -index 599aef9..e860f65 100755 ---- a/scripts/update-po -+++ b/scripts/update-po -@@ -2,7 +2,7 @@ - - # Bootstrap this package from CVS. - --# Copyright (C) 2003-2007, 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2003-2007, 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/help-version.sh b/tests/help-version.sh -index 8b11824..b8053d4 100755 ---- a/tests/help-version.sh -+++ b/tests/help-version.sh -@@ -2,7 +2,7 @@ - # Make sure all these programs work properly - # when invoked with --help or --version. - --# Copyright (C) 2000-2012 Free Software Foundation, Inc. -+# Copyright (C) 2000-2013 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/init.sh b/tests/init.sh -index 5f6e638..bd2048e 100644 ---- a/tests/init.sh -+++ b/tests/init.sh -@@ -1,6 +1,6 @@ - # source this file; set up for tests - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0000-basic.sh b/tests/t0000-basic.sh -index 8178ff3..4aca28b 100755 ---- a/tests/t0000-basic.sh -+++ b/tests/t0000-basic.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that a simple command using -s succeeds with no prompt - --# Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0001-tiny.sh b/tests/t0001-tiny.sh -index 977433e..f3d7b6c 100755 ---- a/tests/t0001-tiny.sh -+++ b/tests/t0001-tiny.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # operate on a very small (1-sector) "disk" - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0010-script-no-ctrl-chars.sh b/tests/t0010-script-no-ctrl-chars.sh -index 7ee43a1..947f608 100755 ---- a/tests/t0010-script-no-ctrl-chars.sh -+++ b/tests/t0010-script-no-ctrl-chars.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that printing with -s outputs no readline control chars - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0100-print.sh b/tests/t0100-print.sh -index 41d4060..d23cfea 100755 ---- a/tests/t0100-print.sh -+++ b/tests/t0100-print.sh -@@ -1,6 +1,6 @@ - #!/bin/sh - # the most basic 'print' test --# Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0101-print-empty.sh b/tests/t0101-print-empty.sh -index 7833a6d..75b5aa5 100755 ---- a/tests/t0101-print-empty.sh -+++ b/tests/t0101-print-empty.sh -@@ -1,6 +1,6 @@ - #!/bin/sh - # test 'parted $dev print' on empty device (without label) --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0200-gpt.sh b/tests/t0200-gpt.sh -index 62d6a23..36f6cd4 100755 ---- a/tests/t0200-gpt.sh -+++ b/tests/t0200-gpt.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that printing a GPT partition table does not modify it. - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0201-gpt.sh b/tests/t0201-gpt.sh -index 4223ab5..edf99b8 100755 ---- a/tests/t0201-gpt.sh -+++ b/tests/t0201-gpt.sh -@@ -2,7 +2,7 @@ - # avoid failed assertion when creating a GPT on top of an old one for a - # larger device - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0202-gpt-pmbr.sh b/tests/t0202-gpt-pmbr.sh -index 07866f3..f5d5dc8 100755 ---- a/tests/t0202-gpt-pmbr.sh -+++ b/tests/t0202-gpt-pmbr.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Preserve first 446B of the Protected MBR for gpt partitions. - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0203-gpt-create-on-min-sized-device.sh b/tests/t0203-gpt-create-on-min-sized-device.sh -index 4cec64c..da291df 100644 ---- a/tests/t0203-gpt-create-on-min-sized-device.sh -+++ b/tests/t0203-gpt-create-on-min-sized-device.sh -@@ -2,7 +2,7 @@ - # parted 3.1 and prior would exit with no diagnostic when failing - # to create a GPT partition table on a device that was too small. - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0203-gpt-shortened-device-primary-valid.sh b/tests/t0203-gpt-shortened-device-primary-valid.sh -index f59d869..1c8e48e 100755 ---- a/tests/t0203-gpt-shortened-device-primary-valid.sh -+++ b/tests/t0203-gpt-shortened-device-primary-valid.sh -@@ -2,7 +2,7 @@ - # Demonstrate that placing a valid gpt-labeled image on a shorter device - # does not invalidate the primary GPT header. - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0203-gpt-tiny-device-abort.sh b/tests/t0203-gpt-tiny-device-abort.sh -index bf281ff..27bb6b1 100644 ---- a/tests/t0203-gpt-tiny-device-abort.sh -+++ b/tests/t0203-gpt-tiny-device-abort.sh -@@ -2,7 +2,7 @@ - # parted before 3.1 could abort while reading a pathologically small device - # with a valid primary GPT header but no room for the backup header. - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0205-gpt-list-clobbers-pmbr.sh b/tests/t0205-gpt-list-clobbers-pmbr.sh -index 763802b..f12081f 100644 ---- a/tests/t0205-gpt-list-clobbers-pmbr.sh -+++ b/tests/t0205-gpt-list-clobbers-pmbr.sh -@@ -5,7 +5,7 @@ - # GPT/MBR table, merely listing the table with Parted-2.1 would clobber - # the MBR part. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh b/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh -index 402451c..ce67880 100755 ---- a/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh -+++ b/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh -@@ -3,7 +3,7 @@ - # Much like t0205, but with the addition of a corrupt PTE in primary table, - # "parted $device print" would modify $device. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0207-IEC-binary-notation.sh b/tests/t0207-IEC-binary-notation.sh -index 1298be3..0ff538f 100644 ---- a/tests/t0207-IEC-binary-notation.sh -+++ b/tests/t0207-IEC-binary-notation.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Show how parted treats a starting or ending sector number w/IEC units. - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0208-mkpart-end-in-IEC.sh b/tests/t0208-mkpart-end-in-IEC.sh -index c24818f..33098b4 100644 ---- a/tests/t0208-mkpart-end-in-IEC.sh -+++ b/tests/t0208-mkpart-end-in-IEC.sh -@@ -2,7 +2,7 @@ - # Make sure parted mkpart ends the partition one sector before the specified - # value if end is specified with IEC units. - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0209-gpt-pmbr_boot.sh b/tests/t0209-gpt-pmbr_boot.sh -index d62d1cd..277a356 100755 ---- a/tests/t0209-gpt-pmbr_boot.sh -+++ b/tests/t0209-gpt-pmbr_boot.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that pmbr_boot flag can be set - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0210-gpt-resized-partition-entry-array.sh b/tests/t0210-gpt-resized-partition-entry-array.sh -index 29efa16..8854018 100755 ---- a/tests/t0210-gpt-resized-partition-entry-array.sh -+++ b/tests/t0210-gpt-resized-partition-entry-array.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # exercise GPT handling of n_partition_array_entries != 128 - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0211-gpt-rewrite-header.sh b/tests/t0211-gpt-rewrite-header.sh -index 85fe5a2..58625a2 100644 ---- a/tests/t0211-gpt-rewrite-header.sh -+++ b/tests/t0211-gpt-rewrite-header.sh -@@ -5,7 +5,7 @@ - # header to the end of the device. Before parted-3.1, when it attempted - # to do that, starting with a 9-PTE array, it would render the result invalid. - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0212-gpt-many-partitions.sh b/tests/t0212-gpt-many-partitions.sh -index cf0a45d..55591d9 100644 ---- a/tests/t0212-gpt-many-partitions.sh -+++ b/tests/t0212-gpt-many-partitions.sh -@@ -2,7 +2,7 @@ - # gpt: create many partitions - # Before parted-3.1, this would provoke an invalid free. - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0220-gpt-msftres.sh b/tests/t0220-gpt-msftres.sh -index bd14c84..6ce96e8 100755 ---- a/tests/t0220-gpt-msftres.sh -+++ b/tests/t0220-gpt-msftres.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # gpt default "flag" for a partition must not be msftres - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0250-gpt.sh b/tests/t0250-gpt.sh -index 2ab0b69..54b14b3 100755 ---- a/tests/t0250-gpt.sh -+++ b/tests/t0250-gpt.sh -@@ -1,6 +1,6 @@ - #!/bin/sh - # very basic GPT table --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0280-gpt-corrupt.sh b/tests/t0280-gpt-corrupt.sh -index f646a68..80effa0 100755 ---- a/tests/t0280-gpt-corrupt.sh -+++ b/tests/t0280-gpt-corrupt.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # corrupt a GPT table; ensure parted takes notice - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0300-dos-on-gpt.sh b/tests/t0300-dos-on-gpt.sh -index fbe8d7c..bd09a93 100755 ---- a/tests/t0300-dos-on-gpt.sh -+++ b/tests/t0300-dos-on-gpt.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # avoid segfault creating a dos PT on top of a gpt one - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0301-overwrite-gpt-pmbr.sh b/tests/t0301-overwrite-gpt-pmbr.sh -index e7edb66..30756f6 100755 ---- a/tests/t0301-overwrite-gpt-pmbr.sh -+++ b/tests/t0301-overwrite-gpt-pmbr.sh -@@ -2,7 +2,7 @@ - # Test creating a msdos partition over a GPT partition with - # fdisk which doesn't remove the GPT partitions, only the PMBR - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0350-mac-PT-increases-sector-size.sh b/tests/t0350-mac-PT-increases-sector-size.sh -index 2dbd8cd..45af404 100644 ---- a/tests/t0350-mac-PT-increases-sector-size.sh -+++ b/tests/t0350-mac-PT-increases-sector-size.sh -@@ -3,7 +3,7 @@ - # larger than what the kernel told us (SS) would cause parted to read B - # bytes into a smaller, SS-byte buffer, clobbering heap storage. - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0400-loop-clobber-infloop.sh b/tests/t0400-loop-clobber-infloop.sh -index 4e35f75..b1fc32d 100644 ---- a/tests/t0400-loop-clobber-infloop.sh -+++ b/tests/t0400-loop-clobber-infloop.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # do not infloop in loop_clobber - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0500-dup-clobber.sh b/tests/t0500-dup-clobber.sh -index a29716d..28c664d 100644 ---- a/tests/t0500-dup-clobber.sh -+++ b/tests/t0500-dup-clobber.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Drive the dup-clobber program. - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0501-duplicate.sh b/tests/t0501-duplicate.sh -index 966e5fb..8affad4 100644 ---- a/tests/t0501-duplicate.sh -+++ b/tests/t0501-duplicate.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Drive the dup-clobber program. - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t1100-busy-label.sh b/tests/t1100-busy-label.sh -index 9e371da..a69b1f3 100755 ---- a/tests/t1100-busy-label.sh -+++ b/tests/t1100-busy-label.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # partitioning (parted -s DEV mklabel) a busy disk must fail. - --# Copyright (C) 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t1101-busy-partition.sh b/tests/t1101-busy-partition.sh -index 710c396..81ccdb8 100755 ---- a/tests/t1101-busy-partition.sh -+++ b/tests/t1101-busy-partition.sh -@@ -2,7 +2,7 @@ - # test for Debian bug #582818 (http://bugs.debian.org/582818); forbid - # the removal of a mounted partition. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index c40bc7a..7ce53d0 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Probe Ext2, Ext3 and Ext4 file systems - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2200-dos-label-recog.sh b/tests/t2200-dos-label-recog.sh -index 478ca67..5ca0010 100755 ---- a/tests/t2200-dos-label-recog.sh -+++ b/tests/t2200-dos-label-recog.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # improved MSDOS partition-table recognition - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2201-pc98-label-recog.sh b/tests/t2201-pc98-label-recog.sh -index 8aed7af..83c30df 100755 ---- a/tests/t2201-pc98-label-recog.sh -+++ b/tests/t2201-pc98-label-recog.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Recognize PC98 labeled disks - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2300-dos-label-extended-bootcode.sh b/tests/t2300-dos-label-extended-bootcode.sh -index c2955d4..b0c26bb 100755 ---- a/tests/t2300-dos-label-extended-bootcode.sh -+++ b/tests/t2300-dos-label-extended-bootcode.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure parted preserves bootcode in extended partition. - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2310-dos-extended-2-sector-min-offset.sh b/tests/t2310-dos-extended-2-sector-min-offset.sh -index 17c777c..fe356dd 100644 ---- a/tests/t2310-dos-extended-2-sector-min-offset.sh -+++ b/tests/t2310-dos-extended-2-sector-min-offset.sh -@@ -4,7 +4,7 @@ - # Before parted-2.3, it could be made to leave just one, and that - # would cause trouble with the Linux kernel. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2400-dos-hfs-partition-type.sh b/tests/t2400-dos-hfs-partition-type.sh -index 59f2b02..feb43c5 100644 ---- a/tests/t2400-dos-hfs-partition-type.sh -+++ b/tests/t2400-dos-hfs-partition-type.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that an HFS partition in a dos table gets the right ID - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2500-probe-corrupt-hfs.sh b/tests/t2500-probe-corrupt-hfs.sh -index 9000366..d8a5f1c 100755 ---- a/tests/t2500-probe-corrupt-hfs.sh -+++ b/tests/t2500-probe-corrupt-hfs.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Do not misbehave when probing a corrupt HFS partition. - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3000-resize-fs.sh b/tests/t3000-resize-fs.sh -index 2fd36a5..a518080 100755 ---- a/tests/t3000-resize-fs.sh -+++ b/tests/t3000-resize-fs.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # exercise the resize library; FAT and HFS+ only - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3200-type-change.sh b/tests/t3200-type-change.sh -index 2b1ee00..a03fd8c 100755 ---- a/tests/t3200-type-change.sh -+++ b/tests/t3200-type-change.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure parted doesn't change the type of a partition to match its FS. - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3300-palo-prep.sh b/tests/t3300-palo-prep.sh -index c690ad7..4050414 100755 ---- a/tests/t3300-palo-prep.sh -+++ b/tests/t3300-palo-prep.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that palo and prep types work properly. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3310-flags.sh b/tests/t3310-flags.sh -index 10997ef..94b2f2a 100644 ---- a/tests/t3310-flags.sh -+++ b/tests/t3310-flags.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Exercise the exclusive, single-bit flags. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3400-whole-disk-FAT-partition.sh b/tests/t3400-whole-disk-FAT-partition.sh -index d0a1231..68f0479 100755 ---- a/tests/t3400-whole-disk-FAT-partition.sh -+++ b/tests/t3400-whole-disk-FAT-partition.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that a whole-disk FAT partition is detected. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4000-sun-raid-type.sh b/tests/t4000-sun-raid-type.sh -index a38000f..66905cf 100755 ---- a/tests/t4000-sun-raid-type.sh -+++ b/tests/t4000-sun-raid-type.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # RAID support on sun disk type - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4001-sun-vtoc.sh b/tests/t4001-sun-vtoc.sh -index 328e9ba..090e070 100755 ---- a/tests/t4001-sun-vtoc.sh -+++ b/tests/t4001-sun-vtoc.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that Sun VTOC is properly initialized. - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4100-dvh-partition-limits.sh b/tests/t4100-dvh-partition-limits.sh -index d885502..a1bc69a 100755 ---- a/tests/t4100-dvh-partition-limits.sh -+++ b/tests/t4100-dvh-partition-limits.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # enforce limits on partition start sector and length - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4100-msdos-partition-limits.sh b/tests/t4100-msdos-partition-limits.sh -index ec1854f..65bda25 100755 ---- a/tests/t4100-msdos-partition-limits.sh -+++ b/tests/t4100-msdos-partition-limits.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # enforce limits on partition start sector and length - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4100-msdos-starting-sector.sh b/tests/t4100-msdos-starting-sector.sh -index d4facfe..37b9875 100755 ---- a/tests/t4100-msdos-starting-sector.sh -+++ b/tests/t4100-msdos-starting-sector.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Consistency in msdos free space starting sector. - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4200-partprobe.sh b/tests/t4200-partprobe.sh -index 26f0e7e..5ae1a42 100755 ---- a/tests/t4200-partprobe.sh -+++ b/tests/t4200-partprobe.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # partprobe must not examine more than 16 partitions - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4300-nilfs2-tiny.sh b/tests/t4300-nilfs2-tiny.sh -index b58e733..523b6bd 100755 ---- a/tests/t4300-nilfs2-tiny.sh -+++ b/tests/t4300-nilfs2-tiny.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Trigger a nilfs2-related bug. - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t5000-tags.sh b/tests/t5000-tags.sh -index a5e49a1..1d443c3 100755 ---- a/tests/t5000-tags.sh -+++ b/tests/t5000-tags.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # test bios_grub flag in gpt labels - --# Copyright (C) 2007-2012 Free Software Foundation, Inc. -+# Copyright (C) 2007-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6000-dm.sh b/tests/t6000-dm.sh -index 8ba0c3e..c301dee 100755 ---- a/tests/t6000-dm.sh -+++ b/tests/t6000-dm.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # ensure that parted can distinguish device map types: linear, multipath - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6001-psep.sh b/tests/t6001-psep.sh -index 1859ac9..da6b8a1 100644 ---- a/tests/t6001-psep.sh -+++ b/tests/t6001-psep.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # ensure that parted names partitions on dm disks correctly - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6002-dm-busy.sh b/tests/t6002-dm-busy.sh -index 9807b40..c02bf81 100644 ---- a/tests/t6002-dm-busy.sh -+++ b/tests/t6002-dm-busy.sh -@@ -2,7 +2,7 @@ - # ensure that parted can alter a partition on a dmraid disk - # while another one is mounted - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6003-dm-hide.sh b/tests/t6003-dm-hide.sh -index 59baae9..fce1f31 100644 ---- a/tests/t6003-dm-hide.sh -+++ b/tests/t6003-dm-hide.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # ensure that parted -l only shows dmraid device-mapper devices - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6100-mdraid-partitions.sh b/tests/t6100-mdraid-partitions.sh -index aedf69b..e980b5d 100755 ---- a/tests/t6100-mdraid-partitions.sh -+++ b/tests/t6100-mdraid-partitions.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # verify that new kernel is informed about partitions on mdraid devices - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t7000-scripting.sh b/tests/t7000-scripting.sh -index 859acda..94f5409 100755 ---- a/tests/t7000-scripting.sh -+++ b/tests/t7000-scripting.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Make sure the scripting option works (-s) properly. - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t8000-loop.sh b/tests/t8000-loop.sh -index 0939b6f..ca4cdc4 100755 ---- a/tests/t8000-loop.sh -+++ b/tests/t8000-loop.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Test usage of loop devices - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t8001-loop-blkpg.sh b/tests/t8001-loop-blkpg.sh -index 9afde4a..ad363ff 100755 ---- a/tests/t8001-loop-blkpg.sh -+++ b/tests/t8001-loop-blkpg.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Test support for partitions on loop devices - --# Copyright (C) 2008-2012 Free Software Foundation, Inc. -+# Copyright (C) 2008-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9010-big-sector.sh b/tests/t9010-big-sector.sh -index a81b9ab..4c15327 100755 ---- a/tests/t9010-big-sector.sh -+++ b/tests/t9010-big-sector.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # check physical sector size as reported by 'print' - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9020-alignment.sh b/tests/t9020-alignment.sh -index 47b445f..482202f 100755 ---- a/tests/t9020-alignment.sh -+++ b/tests/t9020-alignment.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # verify that new alignment-querying functions work - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9021-maxima.sh b/tests/t9021-maxima.sh -index ca10d17..97b5bbe 100755 ---- a/tests/t9021-maxima.sh -+++ b/tests/t9021-maxima.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # verify that partition maxima-querying functions work - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9022-one-unit-snap.sh b/tests/t9022-one-unit-snap.sh -index 9ebc53e..844a78f 100644 ---- a/tests/t9022-one-unit-snap.sh -+++ b/tests/t9022-one-unit-snap.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Confirm that specifying 1 unit snaps to the correct value - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9023-value-lt-one.sh b/tests/t9023-value-lt-one.sh -index 8877c7e..cb8fb5f 100644 ---- a/tests/t9023-value-lt-one.sh -+++ b/tests/t9023-value-lt-one.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Confirm that a value between 0 and 1 throws an error - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9030-align-check.sh b/tests/t9030-align-check.sh -index f0830f0..ed88f8b 100644 ---- a/tests/t9030-align-check.sh -+++ b/tests/t9030-align-check.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # exercise the align-check command - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9040-many-partitions.sh b/tests/t9040-many-partitions.sh -index 8949310..e9461f6 100644 ---- a/tests/t9040-many-partitions.sh -+++ b/tests/t9040-many-partitions.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that creating many partitions works. - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9041-undetected-in-use-16th-partition.sh b/tests/t9041-undetected-in-use-16th-partition.sh -index 6ddc7d8..2c4390d 100644 ---- a/tests/t9041-undetected-in-use-16th-partition.sh -+++ b/tests/t9041-undetected-in-use-16th-partition.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that parted knows when N'th (N>=16) partition is mounted - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9042-dos-partition-limit.sh b/tests/t9042-dos-partition-limit.sh -index 67ea86d..f3f8ced 100644 ---- a/tests/t9042-dos-partition-limit.sh -+++ b/tests/t9042-dos-partition-limit.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that parted enforces msdos partition limit - --# Copyright (C) 2010-2012 Free Software Foundation, Inc. -+# Copyright (C) 2010-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9050-partition-table-types.sh b/tests/t9050-partition-table-types.sh -index 04dc5c6..d73f45e 100755 ---- a/tests/t9050-partition-table-types.sh -+++ b/tests/t9050-partition-table-types.sh -@@ -3,7 +3,7 @@ - # I.e., write a partition table of type T, and then overwrite it - # with one of type V, for every permutation of T and V. - --# Copyright (C) 2011-2012 Free Software Foundation, Inc. -+# Copyright (C) 2011-2013 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by --- -1.9.3 - diff --git a/0052-maint-avoid-new-warning-error-with-gcc-4.8.0-2013010.patch b/0052-maint-avoid-new-warning-error-with-gcc-4.8.0-2013010.patch deleted file mode 100644 index e2f91cb..0000000 --- a/0052-maint-avoid-new-warning-error-with-gcc-4.8.0-2013010.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 1c659d5cc6830c6f4f26660e9049582afbad3fd3 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 6 Jan 2013 11:37:15 +0100 -Subject: [PATCH 052/131] maint: avoid new warning/error with gcc-4.8.0 - 20130105 - -* configure.ac (WERROR_CFLAGS): Disable -Wsuggest-attribute=format. -It was suggesting to apply the gnu_printf attribute to vsnprintf. ---- - configure.ac | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/configure.ac b/configure.ac -index fef0b53..b04eb3f 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -235,6 +235,7 @@ if test "$gl_gcc_warnings" = yes; then - nw="$nw -Wstrict-overflow" # expr.c, pr.c, tr.c, factor.c - nw="$nw -Wstack-protector" # libparted/label/gpt.c - # ?? -Wstrict-overflow -+ nw="$nw -Wsuggest-attribute=format" # suggests to use gnu_printf for vsnprintf - - gl_MANYWARN_ALL_GCC([ws]) - gl_MANYWARN_COMPLEMENT([ws], [$ws], [$nw]) --- -1.9.3 - diff --git a/0053-dos-improve-MBR-signature-generation.patch b/0053-dos-improve-MBR-signature-generation.patch deleted file mode 100644 index a963467..0000000 --- a/0053-dos-improve-MBR-signature-generation.patch +++ /dev/null @@ -1,158 +0,0 @@ -From 70aa35b2b4d2e723fe82ac3184e5921a52be73ab Mon Sep 17 00:00:00 2001 -From: Jonathan Liu -Date: Fri, 4 Oct 2013 07:32:12 -0700 -Subject: [PATCH 053/131] dos: improve MBR signature generation - -Using tv_usec in struct timeval from gettimeofday() doesn't provide -enough precision to fill an unsigned 32-bit integer and isn't really -random. It it always less than one million when using the GNU C library -while an unsigned 32-bit integer ranges between 0 and 4294967295. - -In FAT filesystem creation, parted already uses a better random -generator, so move that code into a common function and use it -for MS-DOS MBR signature generation. - -* libparted/fs/r/fat/fat.c (_gen_new_serial_number): Remove. -(fat_create): Use generate_random_uint32 instead of -_gen_new_serial_number. -* libparted/labels/dos.c (generate_random_id): Remove. -(msdos_write): Use generate_random_uint32 instead of -generate_random_id. -* libparted/labels/misc.h (generate_random_uint32): New function. -Created from _gen_new_serial_number in libparted/fs/r/fat/fat.c with -additional check to avoid returning zero, which may be interpreted -as no FAT serial number or no MBR signature. ---- - NEWS | 4 ++++ - libparted/fs/r/fat/fat.c | 19 ++----------------- - libparted/labels/dos.c | 12 +----------- - libparted/labels/misc.h | 21 +++++++++++++++++++++ - 4 files changed, 28 insertions(+), 28 deletions(-) - -diff --git a/NEWS b/NEWS -index 98f7c6e..50faf4d 100644 ---- a/NEWS -+++ b/NEWS -@@ -23,6 +23,10 @@ GNU parted NEWS -*- outline -*- - partprobe now tells the kernel to forget about any partitions - on a device that has no recognizable partition table. - -+ dos: the range of random MBR signature values was artificially limited -+ to 0..999999, which mistakenly included 0. Now, we use the full 32-bit -+ range, but exclude 0. -+ - ** Changes in behavior - - parted -l no longer lists device-mapper devices other than -diff --git a/libparted/fs/r/fat/fat.c b/libparted/fs/r/fat/fat.c -index 2ab9279..c8e4552 100644 ---- a/libparted/fs/r/fat/fat.c -+++ b/libparted/fs/r/fat/fat.c -@@ -18,10 +18,10 @@ - - #include - #include --#include - - #include "fat.h" - #include "calc.h" -+#include "../../../labels/misc.h" - - PedFileSystem* - fat_alloc (const PedGeometry* geom) -@@ -202,21 +202,6 @@ fat_root_dir_clear (PedFileSystem* fs) - fs_info->root_dir_sector_count); - } - --/* hack: use the ext2 uuid library to generate a reasonably random (hopefully -- * with /dev/random) number. Unfortunately, we can only use 4 bytes of it -- */ --static uint32_t --_gen_new_serial_number (void) --{ -- union { -- uuid_t uuid; -- uint32_t i; -- } uu32; -- -- uuid_generate (uu32.uuid); -- return uu32.i; --} -- - PedFileSystem* - fat_create (PedGeometry* geom, FatType fat_type, PedTimer* timer) - { -@@ -316,7 +301,7 @@ fat_create (PedGeometry* geom, FatType fat_type, PedTimer* timer) - return 0; - } - -- fs_info->serial_number = _gen_new_serial_number (); -+ fs_info->serial_number = generate_random_uint32 (); - - if (!fat_boot_sector_set_boot_code (&fs_info->boot_sector)) - goto error_free_buffers; -diff --git a/libparted/labels/dos.c b/libparted/labels/dos.c -index b8c161f..6bddd79 100644 ---- a/libparted/labels/dos.c -+++ b/libparted/labels/dos.c -@@ -1236,16 +1236,6 @@ write_extended_partitions (const PedDisk* disk) - return write_empty_table (disk, ext_part->geom.start); - } - --static inline uint32_t generate_random_id (void) --{ -- struct timeval tv; -- int rc; -- rc = gettimeofday(&tv, NULL); -- if (rc == -1) -- return 0; -- return (uint32_t)(tv.tv_usec & 0xFFFFFFFFUL); --} -- - static int - msdos_write (const PedDisk* disk) - { -@@ -1267,7 +1257,7 @@ msdos_write (const PedDisk* disk) - - /* If there is no unique identifier, generate a random one */ - if (!table->mbr_signature) -- table->mbr_signature = generate_random_id(); -+ table->mbr_signature = generate_random_uint32 (); - - memset (table->partitions, 0, sizeof (table->partitions)); - table->magic = PED_CPU_TO_LE16 (MSDOS_MAGIC); -diff --git a/libparted/labels/misc.h b/libparted/labels/misc.h -index c2ccea1..c039c5f 100644 ---- a/libparted/labels/misc.h -+++ b/libparted/labels/misc.h -@@ -16,6 +16,27 @@ - You should have received a copy of the GNU General Public License - along with this program. If not, see . */ - -+#include -+#include -+ -+/* hack: use the ext2 uuid library to generate a reasonably random (hopefully -+ * with /dev/random) number. Unfortunately, we can only use 4 bytes of it. -+ * We make sure to avoid returning zero which may be interpreted as no FAT -+ * serial number or no MBR signature. -+ */ -+static inline uint32_t -+generate_random_uint32 (void) -+{ -+ union { -+ uuid_t uuid; -+ uint32_t i; -+ } uu32; -+ -+ uuid_generate (uu32.uuid); -+ -+ return uu32.i > 0 ? uu32.i : 0xffffffff; -+} -+ - /* Return nonzero if FS_TYPE_NAME starts with "linux-swap". - This must match the NUL-terminated "linux-swap" as well - as "linux-swap(v0)" and "linux-swap(v1)". */ --- -1.9.3 - diff --git a/0054-bootstrap-update-to-latest-from-gnulib.patch b/0054-bootstrap-update-to-latest-from-gnulib.patch deleted file mode 100644 index 95f56da..0000000 --- a/0054-bootstrap-update-to-latest-from-gnulib.patch +++ /dev/null @@ -1,324 +0,0 @@ -From 9b8f632e102c0d9e2187f0c8d8205862540cdcd1 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 9 Oct 2013 17:44:05 -0700 -Subject: [PATCH 054/131] bootstrap: update to latest from gnulib - ---- - bootstrap | 159 ++++++++++++++++++++++++++++++++++---------------------------- - 1 file changed, 87 insertions(+), 72 deletions(-) - -diff --git a/bootstrap b/bootstrap -index 48181c9..e31d17d 100755 ---- a/bootstrap -+++ b/bootstrap -@@ -1,6 +1,6 @@ - #! /bin/sh - # Print a version string. --scriptversion=2012-07-19.14; # UTC -+scriptversion=2013-08-15.22; # UTC - - # Bootstrap this package from checked-out sources. - -@@ -140,20 +140,21 @@ po_download_command_format2=\ - "wget --mirror -nd -q -np -A.po -P '%s' \ - http://translationproject.org/latest/%s/" - -+# Prefer a non-empty tarname (4th argument of AC_INIT if given), else -+# fall back to the package name (1st argument with munging) - extract_package_name=' -- /^AC_INIT(/{ -- /.*,.*,.*, */{ -- s/// -- s/[][]//g -- s/)$// -+ /^AC_INIT(\[*/{ -+ s/// -+ /^[^,]*,[^,]*,[^,]*,[ []*\([^][ ,)]\)/{ -+ s//\1/ -+ s/[],)].*// - p - q - } -- s/AC_INIT(\[*// -- s/]*,.*// -+ s/[],)].*// - s/^GNU // - y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ -- s/[^A-Za-z0-9_]/-/g -+ s/[^abcdefghijklmnopqrstuvwxyz0123456789_]/-/g - p - } - ' -@@ -208,12 +209,16 @@ bootstrap_sync=false - # Use git to update gnulib sources - use_git=true - -+check_exists() { -+ ($1 --version /dev/null 2>&1 -+ test $? -lt 126 -+} -+ - # find_tool ENVVAR NAMES... - # ------------------------- - # Search for a required program. Use the value of ENVVAR, if set, --# otherwise find the first of the NAMES that can be run (i.e., --# supports --version). If found, set ENVVAR to the program name, --# die otherwise. -+# otherwise find the first of the NAMES that can be run. -+# If found, set ENVVAR to the program name, die otherwise. - # - # FIXME: code duplication, see also gnu-web-doc-update. - find_tool () -@@ -223,27 +228,21 @@ find_tool () - find_tool_names=$@ - eval "find_tool_res=\$$find_tool_envvar" - if test x"$find_tool_res" = x; then -- for i -- do -- if ($i --version /dev/null 2>&1; then -- find_tool_res=$i -- break -+ for i; do -+ if check_exists $i; then -+ find_tool_res=$i -+ break - fi - done -- else -- find_tool_error_prefix="\$$find_tool_envvar: " - fi -- test x"$find_tool_res" != x \ -- || die "one of these is required: $find_tool_names" -- ($find_tool_res --version /dev/null 2>&1 \ -- || die "${find_tool_error_prefix}cannot run $find_tool_res --version" -+ if test x"$find_tool_res" = x; then -+ warn_ "one of these is required: $find_tool_names;" -+ die "alternatively set $find_tool_envvar to a compatible tool" -+ fi - eval "$find_tool_envvar=\$find_tool_res" - eval "export $find_tool_envvar" - } - --# Find sha1sum, named gsha1sum on MacPorts, and shasum on Mac OS X 10.6. --find_tool SHA1SUM sha1sum gsha1sum shasum -- - # Override the default configuration, if necessary. - # Make sure that bootstrap.conf is sourced from the current directory - # if we were invoked as "sh bootstrap". -@@ -255,12 +254,12 @@ esac - # Extra files from gnulib, which override files from other sources. - test -z "${gnulib_extra_files}" && \ - gnulib_extra_files=" -- $build_aux/install-sh -- $build_aux/mdate-sh -- $build_aux/texinfo.tex -- $build_aux/depcomp -- $build_aux/config.guess -- $build_aux/config.sub -+ build-aux/install-sh -+ build-aux/mdate-sh -+ build-aux/texinfo.tex -+ build-aux/depcomp -+ build-aux/config.guess -+ build-aux/config.sub - doc/INSTALL - " - -@@ -306,34 +305,34 @@ if test -n "$checkout_only_file" && test ! -r "$checkout_only_file"; then - die "Bootstrapping from a non-checked-out distribution is risky." - fi - --# Ensure that lines starting with ! sort last, per gitignore conventions --# for whitelisting exceptions after a more generic blacklist pattern. --sort_patterns() { -- sort -u "$@" | sed '/^!/ { -- H -- d -- } -- $ { -- P -- x -- s/^\n// -- }' | sed '/^$/d' -+# Strip blank and comment lines to leave significant entries. -+gitignore_entries() { -+ sed '/^#/d; /^$/d' "$@" - } - --# If $STR is not already on a line by itself in $FILE, insert it, --# sorting the new contents of the file and replacing $FILE with the result. --insert_sorted_if_absent() { -+# If $STR is not already on a line by itself in $FILE, insert it at the start. -+# Entries are inserted at the start of the ignore list to ensure existing -+# entries starting with ! are not overridden. Such entries support -+# whitelisting exceptions after a more generic blacklist pattern. -+insert_if_absent() { - file=$1 - str=$2 - test -f $file || touch $file -- echo "$str" | sort_patterns - $file | cmp -s - $file > /dev/null \ -- || { echo "$str" | sort_patterns - $file > $file.bak \ -- && mv $file.bak $file; } \ -- || die "insert_sorted_if_absent $file $str: failed" -+ test -r $file || die "Error: failed to read ignore file: $file" -+ duplicate_entries=$(gitignore_entries $file | sort | uniq -d) -+ if [ "$duplicate_entries" ] ; then -+ die "Error: Duplicate entries in $file: " $duplicate_entries -+ fi -+ linesold=$(gitignore_entries $file | wc -l) -+ linesnew=$( { echo "$str"; cat $file; } | gitignore_entries | sort -u | wc -l) -+ if [ $linesold != $linesnew ] ; then -+ { echo "$str" | cat - $file > $file.bak && mv $file.bak $file; } \ -+ || die "insert_if_absent $file $str: failed" -+ fi - } - - # Adjust $PATTERN for $VC_IGNORE_FILE and insert it with --# insert_sorted_if_absent. -+# insert_if_absent. - insert_vc_ignore() { - vc_ignore_file="$1" - pattern="$2" -@@ -344,7 +343,7 @@ insert_vc_ignore() { - # .gitignore entry. - pattern=$(echo "$pattern" | sed s,^,/,);; - esac -- insert_sorted_if_absent "$vc_ignore_file" "$pattern" -+ insert_if_absent "$vc_ignore_file" "$pattern" - } - - # Die if there is no AC_CONFIG_AUX_DIR($build_aux) line in configure.ac. -@@ -468,8 +467,7 @@ check_versions() { - if [ "$req_ver" = "-" ]; then - # Merely require app to exist; not all prereq apps are well-behaved - # so we have to rely on $? rather than get_version. -- $app --version >/dev/null 2>&1 -- if [ 126 -le $? ]; then -+ if ! check_exists $app; then - warn_ "Error: '$app' not found" - ret=1 - fi -@@ -502,6 +500,12 @@ print_versions() { - # can't depend on column -t - } - -+# Find sha1sum, named gsha1sum on MacPorts, shasum on Mac OS X 10.6. -+# Also find the compatible sha1 utility on the BSDs -+if test x"$SKIP_PO" = x; then -+ find_tool SHA1SUM sha1sum gsha1sum shasum sha1 -+fi -+ - use_libtool=0 - # We'd like to use grep -E, to see if any of LT_INIT, - # AC_PROG_LIBTOOL, AM_PROG_LIBTOOL is used in configure.ac, -@@ -550,10 +554,10 @@ fi - echo "$0: Bootstrapping from checked-out $package sources..." - - # See if we can use gnulib's git-merge-changelog merge driver. --if test -d .git && (git --version) >/dev/null 2>/dev/null ; then -+if $use_git && test -d .git && check_exists git; then - if git config merge.merge-changelog.driver >/dev/null ; then - : -- elif (git-merge-changelog --version) >/dev/null 2>/dev/null ; then -+ elif check_exists git-merge-changelog; then - echo "$0: initializing git-merge-changelog driver" - git config merge.merge-changelog.name 'GNU-style ChangeLog merge driver' - git config merge.merge-changelog.driver 'git-merge-changelog %O %A %B' -@@ -573,13 +577,17 @@ git_modules_config () { - test -f .gitmodules && git config --file .gitmodules "$@" - } - --gnulib_path=$(git_modules_config submodule.gnulib.path) --test -z "$gnulib_path" && gnulib_path=gnulib -+if $use_git; then -+ gnulib_path=$(git_modules_config submodule.gnulib.path) -+ test -z "$gnulib_path" && gnulib_path=gnulib -+fi - --# Get gnulib files. -+# Get gnulib files. Populate $GNULIB_SRCDIR, possibly updating a -+# submodule, for use in the rest of the script. - - case ${GNULIB_SRCDIR--} in - -) -+ # Note that $use_git is necessarily true in this case. - if git_modules_config submodule.gnulib.url >/dev/null; then - echo "$0: getting gnulib files..." - git submodule init || exit $? -@@ -600,8 +608,8 @@ case ${GNULIB_SRCDIR--} in - GNULIB_SRCDIR=$gnulib_path - ;; - *) -- # Use GNULIB_SRCDIR as a reference. -- if test -d "$GNULIB_SRCDIR"/.git && \ -+ # Use GNULIB_SRCDIR directly or as a reference. -+ if $use_git && test -d "$GNULIB_SRCDIR"/.git && \ - git_modules_config submodule.gnulib.url >/dev/null; then - echo "$0: getting gnulib files..." - if git submodule -h|grep -- --reference > /dev/null; then -@@ -627,12 +635,19 @@ case ${GNULIB_SRCDIR--} in - ;; - esac - -+# $GNULIB_SRCDIR now points to the version of gnulib to use, and -+# we no longer need to use git or $gnulib_path below here. -+ - if $bootstrap_sync; then - cmp -s "$0" "$GNULIB_SRCDIR/build-aux/bootstrap" || { - echo "$0: updating bootstrap and restarting..." -+ case $(sh -c 'echo "$1"' -- a) in -+ a) ignored=--;; -+ *) ignored=ignored;; -+ esac - exec sh -c \ - 'cp "$1" "$2" && shift && exec "${CONFIG_SHELL-/bin/sh}" "$@"' \ -- -- "$GNULIB_SRCDIR/build-aux/bootstrap" \ -+ $ignored "$GNULIB_SRCDIR/build-aux/bootstrap" \ - "$0" "$@" --no-bootstrap-sync - } - fi -@@ -680,11 +695,10 @@ update_po_files() { - cksum_file="$ref_po_dir/$po.s1" - if ! test -f "$cksum_file" || - ! test -f "$po_dir/$po.po" || -- ! $SHA1SUM -c --status "$cksum_file" \ -- < "$new_po" > /dev/null; then -+ ! $SHA1SUM -c "$cksum_file" < "$new_po" > /dev/null 2>&1; then - echo "$me: updated $po_dir/$po.po..." - cp "$new_po" "$po_dir/$po.po" \ -- && $SHA1SUM < "$new_po" > "$cksum_file" -+ && $SHA1SUM < "$new_po" > "$cksum_file" || return - fi - done - } -@@ -889,20 +903,21 @@ find "$m4_base" "$source_base" \ - -depth \( -name '*.m4' -o -name '*.[ch]' \) \ - -type l -xtype l -delete > /dev/null 2>&1 - -+# Invoke autoreconf with --force --install to ensure upgrades of tools -+# such as ylwrap. -+AUTORECONFFLAGS="--verbose --install --force -I $m4_base $ACLOCAL_FLAGS" -+ - # Some systems (RHEL 5) are using ancient autotools, for which the - # --no-recursive option had not been invented. Detect that lack and - # omit the option when it's not supported. FIXME in 2017: remove this - # hack when RHEL 5 autotools are updated, or when they become irrelevant. --no_recursive= - case $($AUTORECONF --help) in -- *--no-recursive*) no_recursive=--no-recursive;; -+ *--no-recursive*) AUTORECONFFLAGS="$AUTORECONFFLAGS --no-recursive";; - esac - - # Tell autoreconf not to invoke autopoint or libtoolize; they were run above. --echo "running: AUTOPOINT=true LIBTOOLIZE=true " \ -- "$AUTORECONF --verbose --install $no_recursive -I $m4_base $ACLOCAL_FLAGS" --AUTOPOINT=true LIBTOOLIZE=true \ -- $AUTORECONF --verbose --install $no_recursive -I $m4_base $ACLOCAL_FLAGS \ -+echo "running: AUTOPOINT=true LIBTOOLIZE=true $AUTORECONF $AUTORECONFFLAGS" -+AUTOPOINT=true LIBTOOLIZE=true $AUTORECONF $AUTORECONFFLAGS \ - || die "autoreconf failed" - - # Get some extra files from gnulib, overriding existing files. --- -1.9.3 - diff --git a/0055-parted-fix-EOF-and-ctrl-c-handling.patch b/0055-parted-fix-EOF-and-ctrl-c-handling.patch deleted file mode 100644 index bb7aa72..0000000 --- a/0055-parted-fix-EOF-and-ctrl-c-handling.patch +++ /dev/null @@ -1,73 +0,0 @@ -From 8ae195863e7d6950cfcc7a067f52e46f295655a7 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 5 Jan 2013 15:13:50 -0500 -Subject: [PATCH 055/131] parted: fix EOF and ctrl-c handling - -feof() seems to not detect EOF after readline() hits it, so parted went -into an infinite loop prompting for input on EOF. Change test to use the -got_ctrl_c variable instead, which is set when readline hits EOF and -returns NULL. This also makes parted properly exit on ctrl-c. ---- - NEWS | 4 ++++ - parted/ui.c | 16 ++++++---------- - 2 files changed, 10 insertions(+), 10 deletions(-) - -diff --git a/NEWS b/NEWS -index 50faf4d..a27200b 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,10 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ parted: fix EOF and ctrl-c handling. parted used to refuse to exit -+ in response to ctrl-c and would get stuck in an infinite loop -+ prompting for more input when it reached EOF on stdin. -+ - libparted: Don't fail to manipulate partitions on dmraid disks that - have other partitions in use. - -diff --git a/parted/ui.c b/parted/ui.c -index 22790bb..786deed 100644 ---- a/parted/ui.c -+++ b/parted/ui.c -@@ -647,15 +647,7 @@ exception_handler (PedException* ex) - - got_ctrl_c = 0; - -- do { -- opt = command_line_get_ex_opt ("", ex->options); -- } while (opt == PED_EXCEPTION_UNHANDLED -- && (isatty (0) || pretend_input_tty) && !got_ctrl_c); -- -- if (got_ctrl_c) { -- got_ctrl_c = 0; -- opt = PED_EXCEPTION_UNHANDLED; -- } -+ opt = command_line_get_ex_opt ("", ex->options); - - return opt; - } -@@ -900,6 +892,10 @@ command_line_get_word (const char* prompt, const char* def, - - command_line_prompt_words (prompt, def, possibilities, - multi_word); -+ if (got_ctrl_c) { -+ got_ctrl_c = 0; -+ return NULL; -+ } - } while (command_line_get_word_count ()); - - return NULL; -@@ -1581,7 +1577,7 @@ interactive_mode (PedDevice** dev, Command* cmd_list[]) - Command* cmd; - - while (!command_line_get_word_count ()) { -- if (feof (stdin)) { -+ if (got_ctrl_c) { - putchar ('\n'); - return 1; - } --- -1.9.3 - diff --git a/0056-tests-t6003-dm-hide-don-t-hang-on-exception.patch b/0056-tests-t6003-dm-hide-don-t-hang-on-exception.patch deleted file mode 100644 index 156a448..0000000 --- a/0056-tests-t6003-dm-hide-don-t-hang-on-exception.patch +++ /dev/null @@ -1,37 +0,0 @@ -From a1fc166a0791557a54d91e034dfefd994b11622b Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 5 Jan 2013 14:59:03 -0500 -Subject: [PATCH 056/131] tests: t6003-dm-hide: don't hang on exception - -If the parted -l found any exceptions, it would print the prompt, which was -redirected to the log, then hang waiting for input, which never came. Use -script mode to disable the prompts. ---- - tests/t6003-dm-hide.sh | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/tests/t6003-dm-hide.sh b/tests/t6003-dm-hide.sh -index fce1f31..8618adc 100644 ---- a/tests/t6003-dm-hide.sh -+++ b/tests/t6003-dm-hide.sh -@@ -47,7 +47,7 @@ echo 0 2048 linear $d1 0 | dmsetup create $linear_ || fail=1 - dev=/dev/mapper/$linear_ - - # No "DMRAID-" UUID prefix, hence the device should not show up. --parted -l >out 2>&1 -+parted -s -l >out 2>&1 - grep "^Disk $dev:" out && fail=1 - - # Unless we perform both dmsetup-remove *and* losetup -d, -@@ -61,7 +61,7 @@ d1=$(loop_setup_ "$f1") || fail=1 - echo 0 2048 linear $d1 0 | dmsetup create $linear_ -u "DMRAID-fake-$$" || fail=1 - - # Thus, the device should now show up. --parted -l >out 2>&1 -+parted -s -l >out 2>&1 - grep "^Disk $dev:" out || fail=1 - - Exit $fail --- -1.9.3 - diff --git a/0057-gpt-Revert-small-device-commits.patch b/0057-gpt-Revert-small-device-commits.patch deleted file mode 100644 index 7c0b2ba..0000000 --- a/0057-gpt-Revert-small-device-commits.patch +++ /dev/null @@ -1,75 +0,0 @@ -From 62a27ccbdaa29a825a593c9562a5cf55ff9e8db4 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 29 Dec 2012 21:59:08 -0500 -Subject: [PATCH 057/131] gpt: Revert small device commits - -The following commit broke the position of the LastUsableLBA: - -48f236f9: gpt: permit "mklabel gpt" on a 67-sector device - -It introduced an off by one error, leaving LastUsableLBA pointing to -the first sector of the backup partition table instead. - -This effectively reverts that commit, as well as adjusting the subsequent -commits to instead use 68 sectors as the minimum length. I believe -this is the minimum legal size as at 67 sectors, there is no valid -value for FirstUsableLBA and LastUsableLBA. ---- - libparted/labels/gpt.c | 8 ++++---- - tests/t0203-gpt-create-on-min-sized-device.sh | 7 +++---- - 2 files changed, 7 insertions(+), 8 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 490de70..eaf14b5 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -506,16 +506,16 @@ gpt_alloc (const PedDevice *dev) - goto error; - - data_start = 2 + GPT_DEFAULT_PARTITION_ENTRY_ARRAY_SIZE / dev->sector_size; -- data_end = dev->length - 1 -+ data_end = dev->length - 2 - - GPT_DEFAULT_PARTITION_ENTRY_ARRAY_SIZE / dev->sector_size; - -- /* If the device is too small to accommodate GPT headers, reject it. */ -+ /* If the device is too small to accommodate GPT headers and one data -+ sector, reject it. */ - if (data_end < data_start) - { - ped_exception_throw (PED_EXCEPTION_ERROR, - PED_EXCEPTION_OK, -- _("device is so small it cannot even" -- " accommodate GPT headers")); -+ _("device is too small for GPT")); - goto error_free_disk; - } - -diff --git a/tests/t0203-gpt-create-on-min-sized-device.sh b/tests/t0203-gpt-create-on-min-sized-device.sh -index da291df..d95d9cd 100644 ---- a/tests/t0203-gpt-create-on-min-sized-device.sh -+++ b/tests/t0203-gpt-create-on-min-sized-device.sh -@@ -24,7 +24,7 @@ dev=loop-file - ss=$sector_size_ - - # Create the smallest file that can accommodate a GPT partition table. --dd if=/dev/null of=$dev bs=$ss seek=67 || framework_failure -+dd if=/dev/null of=$dev bs=$ss seek=68 || framework_failure - - # create a GPT partition table - parted -s $dev mklabel gpt > out 2>&1 || fail=1 -@@ -34,10 +34,9 @@ compare /dev/null out || fail=1 - # Create a file that is 1 sector smaller, and require failure, - # *with* a diagnostic. - rm -f $dev --dd if=/dev/null of=$dev bs=$ss seek=66 || framework_failure -+dd if=/dev/null of=$dev bs=$ss seek=67 || framework_failure - --echo Error: device is so small it cannot even accommodate GPT headers \ -- > exp || framework_failure -+echo Error: device is too small for GPT > exp || framework_failure - - # Try to create a GPT partition table in too little space. This must fail. - parted -s $dev mklabel gpt > out 2>&1 && fail=1 --- -1.9.3 - diff --git a/0058-libparted-handle-logical-partitions-starting-immedia.patch b/0058-libparted-handle-logical-partitions-starting-immedia.patch deleted file mode 100644 index ac337da..0000000 --- a/0058-libparted-handle-logical-partitions-starting-immedia.patch +++ /dev/null @@ -1,115 +0,0 @@ -From f503870153eda7659b09e52e4adeda3bebf06471 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Thu, 12 Jan 2012 14:53:56 -0500 -Subject: [PATCH 058/131] libparted: handle logical partitions starting - immediately after the EBR - -_blkpg_add_partition() set the length of the extended partition -to 2 sectors to allow LILO to be installed there, beacuse the -linux kernel does this. If a logical partition used that second -sector, adding it would fail beacuse of the overlap. Now -_blkpg_add_partition() will limit the length to only the first -sector if the second is used by a logical partition. - -Previously parted did create the partition table, and after a -reboot, the kernel would recognize the table, and happily create -the extended partition as 2 sectors long, thus overlapping the -logical partition, but when parted tried to recreate the same -table with BLKPG, the kernel rightly rejected it. ---- - NEWS | 8 ++++++++ - libparted/arch/linux.c | 17 +++++++++++++++-- - tests/t2310-dos-extended-2-sector-min-offset.sh | 16 ++++------------ - 3 files changed, 27 insertions(+), 14 deletions(-) - -diff --git a/NEWS b/NEWS -index a27200b..716e477 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,14 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: handle logical partitions starting immediately after -+ the EBR. Creating a logical partition one sector after the EBR -+ used to cause parted to complain that it could not inform the -+ kernel of the changes, but after a reboot, everything was fine. -+ Parted will now correctly inform the kernel of the changes, but -+ only set the length of the extended partition to 1 sector instead -+ of two, which would cause it to overlap the logical partition. -+ - parted: fix EOF and ctrl-c handling. parted used to refuse to exit - in response to ctrl-c and would get stuck in an infinite loop - prompting for more input when it reached EOF on stdin. -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 2bb8774..05794d9 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2473,8 +2473,21 @@ _blkpg_add_partition (PedDisk* disk, const PedPartition *part) - memset (&linux_part, 0, sizeof (linux_part)); - linux_part.start = part->geom.start * disk->dev->sector_size; - /* see fs/partitions/msdos.c:msdos_partition(): "leave room for LILO" */ -- if (part->type & PED_PARTITION_EXTENDED) -- linux_part.length = part->geom.length == 1 ? 512 : 1024; -+ if (part->type & PED_PARTITION_EXTENDED) { -+ linux_part.length = 1; -+ if (disk->dev->sector_size == 512) { -+ if (linux_part.length == 1) -+ linux_part.length = 2; -+ PedPartition *walk; -+ /* if the second sector is claimed by a logical partition, -+ then there's just no room for lilo, so don't try to use it */ -+ for (walk = part->part_list; walk; walk = walk->next) { -+ if (walk->geom.start == part->geom.start+1) -+ linux_part.length = 1; -+ } -+ } -+ linux_part.length *= disk->dev->sector_size; -+ } - else - linux_part.length = part->geom.length * disk->dev->sector_size; - linux_part.pno = part->num; -diff --git a/tests/t2310-dos-extended-2-sector-min-offset.sh b/tests/t2310-dos-extended-2-sector-min-offset.sh -index fe356dd..f74cba5 100644 ---- a/tests/t2310-dos-extended-2-sector-min-offset.sh -+++ b/tests/t2310-dos-extended-2-sector-min-offset.sh -@@ -1,8 +1,6 @@ - #!/bin/sh --# Ensure that parted leaves at least 2 sectors between the beginning -+# Ensure that parted allows a single sector between the beginning - # of an extended partition and the first logical partition. --# Before parted-2.3, it could be made to leave just one, and that --# would cause trouble with the Linux kernel. - - # Copyright (C) 2010-2012 Free Software Foundation, Inc. - -@@ -35,7 +33,7 @@ cat < exp || framework_failure - BYT; - $scsi_dev:2048s:scsi:512:512:msdos:Linux scsi_debug:; - 1:64s:128s:65s:::lba; --5:66s:128s:63s:::; -+5:65s:128s:64s:::; - EOF - - cat < err.exp || framework_failure -@@ -48,15 +46,9 @@ parted --align=min -s $scsi_dev mkpart extended 64s 128s> out 2>&1 || fail=1 - parted -m -s $scsi_dev u s print - compare /dev/null out || fail=1 - --# Provoke a failure by trying to create a partition that starts just -+# Trying to create a partition that starts just - # one sector after the start of the extended partition. --parted --align=min -s $scsi_dev mkpart logical 65s 128s > err 2>&1 && fail=1 --compare err.exp err || fail=1 -- --# The above failed, but created the partition nonetheless. Remove it. --parted -s $scsi_dev rm 5 || fail=1 -- --parted --align=min -s $scsi_dev mkpart logical 66s 128s > out 2>&1 || fail=1 -+parted --align=min -s $scsi_dev mkpart logical 65s 128s > out 2>&1 || fail=1 - compare /dev/null out || fail=1 - - parted -m -s $scsi_dev u s print > out 2>&1 --- -1.9.3 - diff --git a/0059-libparted-fix-gpt-end-of-disk-handling.patch b/0059-libparted-fix-gpt-end-of-disk-handling.patch deleted file mode 100644 index 1cbe080..0000000 --- a/0059-libparted-fix-gpt-end-of-disk-handling.patch +++ /dev/null @@ -1,458 +0,0 @@ -From 9e9588c71e358244bd41f0ca15c10676784ed41d Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Tue, 1 Jan 2013 12:53:35 -0500 -Subject: [PATCH 059/131] libparted: fix gpt end of disk handling - -There are two checks for problems with the end of disk. The first checks -to make sure that the backup gpt is actually at the end of the disk as it -should be. The second checks to see that the gpt's idea of where the disk -ends is correct. The handling of the backup gpt location was wrong because -if you chose not to fix the error, then as soon as you made any changes the -backup would be written to the end of the disk anyhow, only the previous -backup would not be zeroed. - -This patch fixes the write path to put the backup gpt where the gpt says -it goes, not where we think the disk ends. This allows you to choose -not to fix the problems, and the backup gpt will be written to the same -place it was before, not the new end of disk. ---- - NEWS | 6 +++ - libparted/labels/gpt.c | 52 ++++++++++++---------- - tests/Makefile.am | 2 + - tests/gpt-header-move.py | 40 +++++++++++++++++ - tests/t0281-gpt-grow.sh | 99 ++++++++++++++++++++++++++++++++++++++++++ - tests/t0282-gpt-move-backup.sh | 99 ++++++++++++++++++++++++++++++++++++++++++ - 6 files changed, 275 insertions(+), 23 deletions(-) - create mode 100644 tests/gpt-header-move.py - create mode 100644 tests/t0281-gpt-grow.sh - create mode 100644 tests/t0282-gpt-move-backup.sh - -diff --git a/NEWS b/NEWS -index 716e477..3f73434 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,12 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: fix gpt end of disk handling. Previously if the backup -+ copy of the gpt was not at the end of the disk and you chose to -+ ignore this error, parted would move it to the end of the disk -+ anyhow. It will now leave the backup in the same location if -+ you chose to ignore this error. -+ - libparted: handle logical partitions starting immediately after - the EBR. Creating a logical partition one sector after the EBR - used to cause parted to complain that it could not inform the -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index eaf14b5..bcf7812 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -269,6 +269,7 @@ struct __attribute__ ((packed)) _GPTDiskData - int entry_count; - efi_guid_t uuid; - int pmbr_boot; -+ PedSector AlternateLBA; - }; - - /* uses libparted's disk_specific field in PedPartition, to store our info */ -@@ -523,6 +524,7 @@ gpt_alloc (const PedDevice *dev) - if (!disk->disk_specific) - goto error_free_disk; - -+ gpt_disk_data->AlternateLBA = dev->length - 1; - ped_geometry_init (&gpt_disk_data->data_area, dev, data_start, - data_end - data_start + 1); - gpt_disk_data->entry_count = GPT_DEFAULT_PARTITION_ENTRIES; -@@ -748,6 +750,11 @@ _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - if (q == PED_EXCEPTION_FIX) - { - last_usable = last_usable_if_grown; -+ /* clear the old backup gpt header */ -+ ptt_clear_sectors (disk->dev, -+ gpt_disk_data->AlternateLBA, 1); -+ gpt_disk_data->AlternateLBA = disk->dev->length - 1; -+ last_usable = last_usable_if_grown; - *update_needed = 1; - } - else if (q != PED_EXCEPTION_UNHANDLED) -@@ -869,13 +876,13 @@ gpt_read_headers (PedDisk const *disk, - else - pth_free (pri); - -- PedSector backup_sector_num = -+ gpt_disk_data->AlternateLBA = - (valid_primary - ? PED_LE64_TO_CPU (pri->AlternateLBA) - : dev->length - 1); - - void *s_bak; -- if (!ptt_read_sector (dev, backup_sector_num, &s_bak)) -+ if (!ptt_read_sector (dev, gpt_disk_data->AlternateLBA ,&s_bak)) - return 1; - t = pth_new_from_raw (dev, s_bak); - free (s_bak); -@@ -883,10 +890,10 @@ gpt_read_headers (PedDisk const *disk, - return 1; - - GuidPartitionTableHeader_t *bak = t; -- if (_header_is_valid (disk, bak, backup_sector_num)) -+ if (_header_is_valid (disk, bak, gpt_disk_data->AlternateLBA)) - { - *backup_gpt = bak; -- *backup_sector_num_p = backup_sector_num; -+ *backup_sector_num_p = gpt_disk_data->AlternateLBA; - } - else - pth_free (bak); -@@ -957,31 +964,30 @@ gpt_read (PedDisk *disk) - { - /* Both are valid. */ - #ifndef DISCOVER_ONLY -- if (PED_LE64_TO_CPU (primary_gpt->AlternateLBA) < disk->dev->length - 1) -+ PedSector gpt_disk_end = PED_LE64_TO_CPU (primary_gpt->LastUsableLBA) + 1; -+ gpt_disk_end += ((PedSector) (PED_LE32_TO_CPU (primary_gpt->NumberOfPartitionEntries)) * -+ (PedSector) (PED_LE32_TO_CPU (primary_gpt->SizeOfPartitionEntry)) / -+ disk->dev->sector_size); -+ -+ gpt_disk_data->AlternateLBA = PED_LE64_TO_CPU (primary_gpt->AlternateLBA); -+ if (PED_LE64_TO_CPU (primary_gpt->AlternateLBA) != gpt_disk_end) - { -- switch (ped_exception_throw -+ if (ped_exception_throw - (PED_EXCEPTION_ERROR, -- (PED_EXCEPTION_FIX | PED_EXCEPTION_CANCEL -- | PED_EXCEPTION_IGNORE), -+ (PED_EXCEPTION_FIX | PED_EXCEPTION_IGNORE), - _("The backup GPT table is not at the end of the disk, as it " -- "should be. This might mean that another operating system " -- "believes the disk is smaller. Fix, by moving the backup " -- "to the end (and removing the old backup)?"))) -+ "should be. Fix, by moving the backup to the end " -+ "(and removing the old backup)?")) == PED_EXCEPTION_FIX) - { -- case PED_EXCEPTION_CANCEL: -- goto error_free_gpt; -- case PED_EXCEPTION_FIX: - ptt_clear_sectors (disk->dev, - PED_LE64_TO_CPU (primary_gpt->AlternateLBA), 1); -+ gpt_disk_data->AlternateLBA = gpt_disk_end; - write_back = 1; -- break; -- default: -- break; - } - } - #endif /* !DISCOVER_ONLY */ -- gpt = primary_gpt; - pth_free (backup_gpt); -+ gpt = primary_gpt; - } - else if (!primary_gpt && !backup_gpt) - { -@@ -1149,15 +1155,15 @@ _generate_header (const PedDisk *disk, int alternate, uint32_t ptes_crc, - * sizeof (GuidPartitionEntry_t)); - PedSector ptes_sectors = (ptes_bytes + ss - 1) / ss; - -- gpt->MyLBA = PED_CPU_TO_LE64 (disk->dev->length - 1); -+ gpt->MyLBA = PED_CPU_TO_LE64 (gpt_disk_data->AlternateLBA); - gpt->AlternateLBA = PED_CPU_TO_LE64 (1); - gpt->PartitionEntryLBA -- = PED_CPU_TO_LE64 (disk->dev->length - 1 - ptes_sectors); -+ = PED_CPU_TO_LE64 (gpt_disk_data->AlternateLBA - ptes_sectors); - } - else - { - gpt->MyLBA = PED_CPU_TO_LE64 (1); -- gpt->AlternateLBA = PED_CPU_TO_LE64 (disk->dev->length - 1); -+ gpt->AlternateLBA = PED_CPU_TO_LE64 (gpt_disk_data->AlternateLBA); - gpt->PartitionEntryLBA = PED_CPU_TO_LE64 (2); - } - -@@ -1262,12 +1268,12 @@ gpt_write (const PedDisk *disk) - pth_free (gpt); - if (pth_raw == NULL) - goto error_free_ptes; -- write_ok = ped_device_write (disk->dev, pth_raw, disk->dev->length - 1, 1); -+ write_ok = ped_device_write (disk->dev, pth_raw, gpt_disk_data->AlternateLBA, 1); - free (pth_raw); - if (!write_ok) - goto error_free_ptes; - if (!ped_device_write (disk->dev, ptes, -- disk->dev->length - 1 - ptes_sectors, ptes_sectors)) -+ gpt_disk_data->AlternateLBA - ptes_sectors, ptes_sectors)) - goto error_free_ptes; - - free (ptes); -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 4ec08da..eaf44a5 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -28,6 +28,8 @@ TESTS = \ - t0220-gpt-msftres.sh \ - t0250-gpt.sh \ - t0280-gpt-corrupt.sh \ -+ t0281-gpt-grow.sh \ -+ t0282-gpt-move-backup.sh \ - t0300-dos-on-gpt.sh \ - t0301-overwrite-gpt-pmbr.sh \ - t0350-mac-PT-increases-sector-size.sh \ -diff --git a/tests/gpt-header-move.py b/tests/gpt-header-move.py -new file mode 100644 -index 0000000..69d1479 ---- /dev/null -+++ b/tests/gpt-header-move.py -@@ -0,0 +1,40 @@ -+# open img file, subtract 33 from altlba address, and move the last 33 sectors -+# back by 33 sectors -+ -+from struct import * -+from zipfile import crc32 -+import array -+import sys -+file = open(sys.argv[1],'rb+') -+file.seek(512) -+gptheader = file.read(512) -+altlba = unpack_from('q', gptheader,offset=32)[0] -+gptheader = array.array('c',gptheader) -+pack_into('Q', gptheader, 32, altlba-33) -+#zero header crc -+pack_into('L', gptheader, 16, 0) -+#compute new crc -+newcrc = ((crc32(buffer(gptheader,0,92))) & 0xFFFFFFFF) -+pack_into('L', gptheader, 16, newcrc) -+file.seek(512) -+file.write(gptheader) -+file.seek(512*altlba) -+gptheader = file.read(512) -+file.seek(512*(altlba-32)) -+backup = file.read(512*32) -+altlba -= 33 -+gptheader = array.array('c',gptheader) -+#update mylba -+pack_into('Q', gptheader, 24, altlba) -+#update table lba -+pack_into('Q', gptheader, 72, altlba-32) -+#zero header crc -+pack_into('L', gptheader, 16, 0) -+#compute new crc -+newcrc = ((crc32(buffer(gptheader,0,92))) & 0xFFFFFFFF) -+pack_into('L', gptheader, 16, newcrc) -+file.seek(512*(altlba-32)) -+file.write(backup) -+file.write(gptheader) -+file.write("\0" * (512 * 33)) -+ -diff --git a/tests/t0281-gpt-grow.sh b/tests/t0281-gpt-grow.sh -new file mode 100644 -index 0000000..e373578 ---- /dev/null -+++ b/tests/t0281-gpt-grow.sh -@@ -0,0 +1,99 @@ -+#!/bin/sh -+# grow a gpt disk, ensure that parted offers to update the gpt size -+ -+# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+require_512_byte_sector_size_ -+dev=loop-file -+ -+ss=$sector_size_ -+n_sectors=5000 -+ -+dd if=/dev/null of=$dev bs=$ss seek=$n_sectors || fail=1 -+ -+# create gpt label -+parted -s $dev mklabel gpt > empty 2>&1 || fail=1 -+compare /dev/null empty || fail=1 -+ -+# print the empty table -+parted -m -s $dev unit s print > t 2>&1 || fail=1 -+sed "s,.*/$dev:,$dev:," t > out || fail=1 -+ -+# check for expected output -+printf "BYT;\n$dev:${n_sectors}s:file:$sector_size_:$sector_size_:gpt::;\n" \ -+ > exp || fail=1 -+compare exp out || fail=1 -+ -+# grow disk -+n_sectors=5500 -+dd if=/dev/null of=$dev bs=$ss seek=$n_sectors || fail=1 -+ -+# printing must warn, but not fix in script mode -+parted -s $dev print > out 2>&1 || fail=1 -+ -+# Transform the actual output, to avoid spurious differences when -+# $PWD contains a symlink-to-dir. Also, remove the ^M ...^M bogosity. -+# normalize the actual output -+mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ -+ -e "s,^.*/lt-parted: ,parted: ," o2 > out -+ -+# check for expected diagnostic -+cat < exp || fail=1 -+Warning: Not all of the space available to DEVICE appears to be used, you can fix the GPT to use all of the space (an extra 500 blocks) or continue with the current setting? -+Model: (file) -+Disk DEVICE: 2816kB -+Sector size (logical/physical): 512B/512B -+Partition Table: gpt -+Disk Flags: -+ -+Number Start End Size File system Name Flags -+ -+EOF -+compare exp out || fail=1 -+ -+# now we fix -+printf 'f\n' | parted ---pretend-input-tty $dev print > out 2>&1 || fail=1 -+ -+# Transform the actual output, to avoid spurious differences when -+# $PWD contains a symlink-to-dir. Also, remove the ^M ...^M bogosity. -+# normalize the actual output -+mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ -+ -e "s,^.*/lt-parted: ,parted: ," o2 > out -+ -+# check for expected diagnostic -+cat < exp || fail=1 -+Warning: Not all of the space available to DEVICE appears to be used, you can fix the GPT to use all of the space (an extra 500 blocks) or continue with the current setting? -+Fix/Ignore? f -+Model: (file) -+Disk DEVICE: 2816kB -+Sector size (logical/physical): 512B/512B -+Partition Table: gpt -+Disk Flags: -+ -+Number Start End Size File system Name Flags -+ -+EOF -+compare exp out || fail=1 -+ -+ -+# Now should not warn -+ -+parted -s $dev print > err 2>&1 || fail=1 -+grep Warning: err > k ; mv k err -+compare err /dev/null || fail=1 -+ -+Exit $fail -diff --git a/tests/t0282-gpt-move-backup.sh b/tests/t0282-gpt-move-backup.sh -new file mode 100644 -index 0000000..9750ed7 ---- /dev/null -+++ b/tests/t0282-gpt-move-backup.sh -@@ -0,0 +1,99 @@ -+#!/bin/sh -+# put backup copy gpt in the wrong place, ensure that -+# parted offers to fix -+ -+# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+require_512_byte_sector_size_ -+dev=loop-file -+ -+ss=$sector_size_ -+n_sectors=5000 -+ -+dd if=/dev/null of=$dev bs=$ss seek=$n_sectors || fail=1 -+ -+# create gpt label -+parted -s $dev mklabel gpt > empty 2>&1 || fail=1 -+compare /dev/null empty || fail=1 -+ -+# print the empty table -+parted -m -s $dev unit s print > t 2>&1 || fail=1 -+sed "s,.*/$dev:,$dev:," t > out || fail=1 -+ -+# check for expected output -+printf "BYT;\n$dev:${n_sectors}s:file:$sector_size_:$sector_size_:gpt::;\n" \ -+ > exp || fail=1 -+compare exp out || fail=1 -+ -+# move the backup -+python ../gpt-header-move.py $dev || fail=1 -+ -+# printing must warn, but not fix in script mode -+parted -s $dev print > out 2>&1 || fail=1 -+ -+# Transform the actual output, to avoid spurious differences when -+# $PWD contains a symlink-to-dir. Also, remove the ^M ...^M bogosity. -+# normalize the actual output -+mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ -+ -e "s,^.*/lt-parted: ,parted: ," o2 > out -+ -+# check for expected diagnostic -+cat < exp || fail=1 -+Error: The backup GPT table is not at the end of the disk, as it should be. Fix, by moving the backup to the end (and removing the old backup)? -+Model: (file) -+Disk DEVICE: 2560kB -+Sector size (logical/physical): 512B/512B -+Partition Table: gpt -+Disk Flags: -+ -+Number Start End Size File system Name Flags -+ -+EOF -+compare exp out || fail=1 -+ -+# now we fix -+printf 'f\n' | parted ---pretend-input-tty $dev print > out 2>&1 || fail=1 -+ -+# Transform the actual output, to avoid spurious differences when -+# $PWD contains a symlink-to-dir. Also, remove the ^M ...^M bogosity. -+# normalize the actual output -+mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ -+ -e "s,^.*/lt-parted: ,parted: ," o2 > out -+ -+# check for expected diagnostic -+cat < exp || fail=1 -+Error: The backup GPT table is not at the end of the disk, as it should be. Fix, by moving the backup to the end (and removing the old backup)? -+Fix/Ignore? f -+Model: (file) -+Disk DEVICE: 2560kB -+Sector size (logical/physical): 512B/512B -+Partition Table: gpt -+Disk Flags: -+ -+Number Start End Size File system Name Flags -+ -+EOF -+compare exp out || fail=1 -+ -+ -+# Now should not warn -+ -+parted -s $dev print > err 2>&1 || fail=1 -+grep Error: err > k ; mv k err -+compare err /dev/null || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0060-libparted-allow-some-common-errors-to-be-ignored.patch b/0060-libparted-allow-some-common-errors-to-be-ignored.patch deleted file mode 100644 index 9acefb1..0000000 --- a/0060-libparted-allow-some-common-errors-to-be-ignored.patch +++ /dev/null @@ -1,387 +0,0 @@ -From fa815ad05db248d78ef214ea79a78c22772a9ffe Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 5 Jan 2013 20:53:29 -0500 -Subject: [PATCH 060/131] libparted: allow some common errors to be ignored - -Partitions that overlap or extend beyond the end of the disk are common -errors that usually result in people having to use other tools to correct -because parted refuses to operate when it sees them. Change these errors -to allow you to ignore them and use parted to correct the problem. ---- - NEWS | 6 ++ - libparted/cs/geom.c | 8 +-- - libparted/disk.c | 89 +++++++----------------- - tests/Makefile.am | 1 + - tests/t0283-overlap-partitions.sh | 143 ++++++++++++++++++++++++++++++++++++++ - 5 files changed, 176 insertions(+), 71 deletions(-) - create mode 100644 tests/t0283-overlap-partitions.sh - -diff --git a/NEWS b/NEWS -index 3f73434..a05be02 100644 ---- a/NEWS -+++ b/NEWS -@@ -2,6 +2,12 @@ GNU parted NEWS -*- outline -*- - - * Noteworthy changes in release ?.? (????-??-??) [?] - -+** New Features -+ -+ You can now choose to ignore errors about partitions that overlap, -+ or are longer than the disk. This allows you to use parted to -+ repair the problem. -+ - ** Bug Fixes - - libparted: fix gpt end of disk handling. Previously if the backup -diff --git a/libparted/cs/geom.c b/libparted/cs/geom.c -index 65c10c5..b8726da 100644 ---- a/libparted/cs/geom.c -+++ b/libparted/cs/geom.c -@@ -153,6 +153,7 @@ ped_geometry_set (PedGeometry* geom, PedSector start, PedSector length) - { - PED_ASSERT (geom != NULL); - PED_ASSERT (geom->dev != NULL); -+ PED_ASSERT (start >= 0); - - if (length < 1) { - ped_exception_throw ( -@@ -162,13 +163,6 @@ ped_geometry_set (PedGeometry* geom, PedSector start, PedSector length) - " (start sector=%jd length=%jd)"), start, length); - return 0; - } -- if (start < 0 || start + length - 1 >= geom->dev->length) { -- ped_exception_throw ( -- PED_EXCEPTION_ERROR, -- PED_EXCEPTION_CANCEL, -- _("Can't have a partition outside the disk!")); -- return 0; -- } - - geom->start = start; - geom->length = length; -diff --git a/libparted/disk.c b/libparted/disk.c -index d3cd5bb..ce71bfc 100644 ---- a/libparted/disk.c -+++ b/libparted/disk.c -@@ -36,6 +36,7 @@ - #include - #include - #include -+#include - - #include "architecture.h" - #include "labels/pt-tools.h" -@@ -404,6 +405,7 @@ _ped_disk_alloc (const PedDevice* dev, const PedDiskType* disk_type) - disk->type = disk_type; - disk->update_mode = 1; - disk->part_list = NULL; -+ disk->needs_clobber = 0; - return disk; - - error: -@@ -917,6 +919,8 @@ _partition_align (PedPartition* part, const PedConstraint* constraint) - PED_ASSERT (disk_type->ops->partition_align != NULL); - PED_ASSERT (part->disk->update_mode); - -+ if (part->disk->needs_clobber) -+ return 1; /* do not attempt to align partitions while reading them */ - return disk_type->ops->partition_align (part, constraint); - } - -@@ -1771,7 +1775,7 @@ _partition_get_overlap_constraint (PedPartition* part, PedGeometry* geom) - walk = ext_part->part_list; - } else { - min_start = 0; -- max_end = part->disk->dev->length - 1; -+ max_end = LLONG_MAX - 1; - walk = part->disk->part_list; - } - -@@ -1797,48 +1801,6 @@ _partition_get_overlap_constraint (PedPartition* part, PedGeometry* geom) - return ped_constraint_new_from_max (&free_space); - } - --/* -- * Returns \c 0 if the partition, \p part overlaps with any partitions on the -- * \p disk. The geometry of \p part is taken to be \p geom, NOT \p part->geom -- * (the idea here is to check if \p geom is valid, before changing \p part). -- * -- * This is useful for seeing if a resized partitions new geometry is going to -- * fit, without the existing geomtry getting in the way. -- * -- * Note: overlap with an extended partition is also allowed, provided that -- * \p geom lies completely inside the extended partition. -- */ --static int _GL_ATTRIBUTE_PURE --_disk_check_part_overlaps (PedDisk* disk, PedPartition* part) --{ -- PedPartition* walk; -- -- PED_ASSERT (disk != NULL); -- PED_ASSERT (part != NULL); -- -- for (walk = ped_disk_next_partition (disk, NULL); walk; -- walk = ped_disk_next_partition (disk, walk)) { -- if (walk->type & PED_PARTITION_FREESPACE) -- continue; -- if (walk == part) -- continue; -- if (part->type & PED_PARTITION_EXTENDED -- && walk->type & PED_PARTITION_LOGICAL) -- continue; -- -- if (ped_geometry_test_overlap (&walk->geom, &part->geom)) { -- if (walk->type & PED_PARTITION_EXTENDED -- && part->type & PED_PARTITION_LOGICAL -- && ped_geometry_test_inside (&walk->geom, -- &part->geom)) -- continue; -- return 0; -- } -- } -- -- return 1; --} -- - static int - _partition_check_basic_sanity (PedDisk* disk, PedPartition* part) - { -@@ -1847,7 +1809,6 @@ _partition_check_basic_sanity (PedDisk* disk, PedPartition* part) - PED_ASSERT (part->disk == disk); - - PED_ASSERT (part->geom.start >= 0); -- PED_ASSERT (part->geom.end < disk->dev->length); - PED_ASSERT (part->geom.start <= part->geom.end); - - if (!ped_disk_type_check_feature (disk->type, PED_DISK_TYPE_EXTENDED) -@@ -1934,29 +1895,30 @@ _check_partition (PedDisk* disk, PedPartition* part) - - if (part->type & PED_PARTITION_LOGICAL - && !ped_geometry_test_inside (&ext_part->geom, &part->geom)) { -- ped_exception_throw ( -+ if (ped_exception_throw ( - PED_EXCEPTION_ERROR, -- PED_EXCEPTION_CANCEL, -+ PED_EXCEPTION_IGNORE_CANCEL, - _("Can't have a logical partition outside of the " - "extended partition on %s."), -- disk->dev->path); -- return 0; -- } -- -- if (!_disk_check_part_overlaps (disk, part)) { -- ped_exception_throw ( -- PED_EXCEPTION_ERROR, -- PED_EXCEPTION_CANCEL, -- _("Can't have overlapping partitions.")); -- return 0; -+ disk->dev->path) != PED_EXCEPTION_IGNORE) -+ return 0; - } - - if (! (part->type & PED_PARTITION_LOGICAL) - && ext_part && ext_part != part - && ped_geometry_test_inside (&ext_part->geom, &part->geom)) { -- ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, -+ if (ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_IGNORE_CANCEL, - _("Can't have a primary partition inside an extended " -- "partition.")); -+ "partition.")) != PED_EXCEPTION_IGNORE) -+ return 0; -+ } -+ -+ if (part->geom.end >= disk->dev->length) { -+ if (ped_exception_throw ( -+ PED_EXCEPTION_ERROR, -+ PED_EXCEPTION_IGNORE_CANCEL, -+ _("Can't have a partition outside the disk!")) -+ != PED_EXCEPTION_IGNORE ) - return 0; - } - -@@ -2003,16 +1965,15 @@ ped_disk_add_partition (PedDisk* disk, PedPartition* part, - constraint); - - if (!constraints && constraint) { -- ped_exception_throw ( -+ if (ped_exception_throw ( - PED_EXCEPTION_ERROR, -- PED_EXCEPTION_CANCEL, -- _("Can't have overlapping partitions.")); -+ PED_EXCEPTION_IGNORE_CANCEL, -+ _("Can't have overlapping partitions.")) != PED_EXCEPTION_IGNORE) - goto error; -- } -- -+ } else constraint = constraints; - if (!_partition_enumerate (part)) - goto error; -- if (!_partition_align (part, constraints)) -+ if (!_partition_align (part, constraint)) - goto error; - } - /* FIXME: when _check_partition fails, we end up leaking PART -diff --git a/tests/Makefile.am b/tests/Makefile.am -index eaf44a5..16ec5d2 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -30,6 +30,7 @@ TESTS = \ - t0280-gpt-corrupt.sh \ - t0281-gpt-grow.sh \ - t0282-gpt-move-backup.sh \ -+ t0283-overlap-partitions.sh \ - t0300-dos-on-gpt.sh \ - t0301-overwrite-gpt-pmbr.sh \ - t0350-mac-PT-increases-sector-size.sh \ -diff --git a/tests/t0283-overlap-partitions.sh b/tests/t0283-overlap-partitions.sh -new file mode 100644 -index 0000000..2a53407 ---- /dev/null -+++ b/tests/t0283-overlap-partitions.sh -@@ -0,0 +1,143 @@ -+#!/bin/sh -+# ensure parted can ignore partitions that overlap or are -+# longer than the disk and remove them -+ -+# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+require_512_byte_sector_size_ -+dev=loop-file -+ -+truncate -s 10m $dev || fail=1 -+ -+# write damaged label -+xxd -r - $dev < out 2>&1 || fail=1 -+print -+ignore -+rm -+ignore -+2 -+EOF -+ -+# $PWD contains a symlink-to-dir. Also, remove the ^M ...^M bogosity. -+# normalize the actual output -+mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ -+ -e "s,^.*/lt-parted: ,parted: ," -e "s/^GNU Parted .*$/GNU Parted VERSION/" o2 > out -+ -+# check for expected output -+cat < exp || fail=1 -+GNU Parted VERSION -+Using DEVICE -+Welcome to GNU Parted! Type 'help' to view a list of commands. -+(parted) print -+Error: Can't have overlapping partitions. -+Ignore/Cancel? ignore -+Model: (file) -+Disk DEVICE: 10.5MB -+Sector size (logical/physical): 512B/512B -+Partition Table: msdos -+Disk Flags: -+ -+Number Start End Size Type File system Flags -+ 1 1049kB 5243kB 4194kB primary -+ 2 5242kB 8000kB 2758kB primary -+ -+(parted) rm -+Error: Can't have overlapping partitions. -+Ignore/Cancel? ignore -+Partition number? 2 -+(parted) -+EOF -+compare exp out || fail=1 -+ -+truncate -s 3m $dev || fail=1 -+ -+# print the table, verify error, ignore it, and remove the partition -+parted ---pretend-input-tty $dev < out 2>&1 || fail=1 -+print -+ignore -+rm -+ignore -+1 -+EOF -+ -+# $PWD contains a symlink-to-dir. Also, remove the ^M ...^M bogosity. -+# normalize the actual output -+mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ -+ -e "s,^.*/lt-parted: ,parted: ," -e "s/^GNU Parted .*$/GNU Parted VERSION/" o2 > out -+ -+# check for expected output -+cat < exp || fail=1 -+GNU Parted VERSION -+Using DEVICE -+Welcome to GNU Parted! Type 'help' to view a list of commands. -+(parted) print -+Error: Can't have a partition outside the disk! -+Ignore/Cancel? ignore -+Model: (file) -+Disk DEVICE: 3146kB -+Sector size (logical/physical): 512B/512B -+Partition Table: msdos -+Disk Flags: -+ -+Number Start End Size Type File system Flags -+ 1 1049kB 5243kB 4194kB primary -+ -+(parted) rm -+Error: Can't have a partition outside the disk! -+Ignore/Cancel? ignore -+Partition number? 1 -+(parted) -+EOF -+compare exp out || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0061-Revert-linux-commit-do-not-unnecessarily-open-partit.patch b/0061-Revert-linux-commit-do-not-unnecessarily-open-partit.patch deleted file mode 100644 index 4b9197c..0000000 --- a/0061-Revert-linux-commit-do-not-unnecessarily-open-partit.patch +++ /dev/null @@ -1,93 +0,0 @@ -From fb99ba5ebd0dc34204fc9f1014131d5d494805bc Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 5 Jan 2013 22:59:35 -0500 -Subject: [PATCH 061/131] Revert "linux-commit: do not unnecessarily open - partition device nodes" - -This reverts commit 2a6936fab4d4499a4b812dd330d3db50549029e0. The commit -disabled flushing the block buffer caches on the partition nodes to ensure -cache consistency on 2.6 kernels, supposedly because this was no longer -required. It appears this was incorrect, and the caches DO still need -flushed, otherwise a new fs written to the partition device does not show -up in the disk device cache, causing parted to still identify the old fs. ---- - NEWS | 5 +++++ - libparted/arch/linux.c | 25 +++---------------------- - 2 files changed, 8 insertions(+), 22 deletions(-) - -diff --git a/NEWS b/NEWS -index a05be02..6538c96 100644 ---- a/NEWS -+++ b/NEWS -@@ -10,6 +10,11 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ Fix cache coherency issue by flushing partition block devices. -+ This had been mistakenly disabled in parted 2.0, and resulted -+ in parted sometimes identifying the previous filesystem type -+ after running an mkfs to format a partition to a new type. -+ - libparted: fix gpt end of disk handling. Previously if the backup - copy of the gpt was not at the end of the disk and you chose to - ignore this error, parted would move it to the end of the disk -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 05794d9..4b1b438 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -703,19 +703,6 @@ _get_linux_version () - return kver = KERNEL_VERSION (major, minor, teeny); - } - --static int --_have_kern26 () --{ -- static int have_kern26 = -1; -- int kver; -- -- if (have_kern26 != -1) -- return have_kern26; -- -- kver = _get_linux_version(); -- return have_kern26 = kver >= KERNEL_VERSION (2,6,0) ? 1 : 0; --} -- - #if USE_BLKID - static void - get_blkid_topology (LinuxSpecific *arch_specific) -@@ -1567,8 +1554,8 @@ linux_is_busy (PedDevice* dev) - return 0; - } - --/* we need to flush the master device, and with kernel < 2.6 all the partition -- * devices, because there is no coherency between the caches with old kernels. -+/* we need to flush the master device, and all the partition devices, -+ * because there is no coherency between the caches. - * We should only flush unmounted partition devices, because: - * - there is never a need to flush them (we're not doing IO there) - * - flushing a device that is mounted causes unnecessary IO, and can -@@ -1586,10 +1573,6 @@ _flush_cache (PedDevice* dev) - - ioctl (arch_specific->fd, BLKFLSBUF); - -- /* With linux-2.6.0 and newer, we're done. */ -- if (_have_kern26()) -- return; -- - for (i = 1; i < 16; i++) { - char* name; - int fd; -@@ -1654,9 +1637,7 @@ retry: - dev->read_only = 0; - } - -- /* With kernels < 2.6 flush cache for cache coherence issues */ -- if (!_have_kern26()) -- _flush_cache (dev); -+ _flush_cache (dev); - - return 1; - } --- -1.9.3 - diff --git a/0062-libparted-avoid-disturbing-partitions.patch b/0062-libparted-avoid-disturbing-partitions.patch deleted file mode 100644 index c6a9063..0000000 --- a/0062-libparted-avoid-disturbing-partitions.patch +++ /dev/null @@ -1,141 +0,0 @@ -From 5910f1bc983fbab31f9ec86a7166feee4869c21a Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 29 Sep 2013 12:38:29 -0400 -Subject: [PATCH 062/131] libparted: avoid disturbing partitions - -The partition sync logic was first removing all -partitions, then trying to re-add them. This resulted in many -udev events triggering annoying behavior like auto mounting. -Refactor the code to avoid removing and re-adding unmodified -partitions. ---- - NEWS | 3 ++ - libparted/arch/linux.c | 84 ++++++++++++++++++++++++++++---------------------- - 2 files changed, 50 insertions(+), 37 deletions(-) - -diff --git a/NEWS b/NEWS -index 6538c96..cb725e7 100644 ---- a/NEWS -+++ b/NEWS -@@ -10,6 +10,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ Avoid generating udev add/remove events for all unmodified partitions -+ when writing a new table. -+ - Fix cache coherency issue by flushing partition block devices. - This had been mistakenly disabled in parted 2.0, and resulted - in parted sometimes identifying the previous filesystem type -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 4b1b438..f43eae1 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2670,6 +2670,11 @@ _dm_get_partition_start_and_length(PedPartition const *part, - return 0; - char *path = _device_get_part_path (part->disk->dev, part->num); - PED_ASSERT(path); -+ /* libdevmapper likes to complain on stderr instead of quietly -+ returning ENOENT or ENXIO, so try to stat first */ -+ struct stat st; -+ if (stat(path, &st)) -+ goto err; - dm_task_set_name(task, path); - if (!dm_task_run(task)) - goto err; -@@ -2806,50 +2811,55 @@ _disk_sync_part_table (PedDisk* disk) - if (!errnums) - goto cleanup; - -- /* Attempt to remove each and every partition, retrying for -- up to max_sleep_seconds upon any failure due to EBUSY. */ -- unsigned int sleep_microseconds = 10000; -- unsigned int max_sleep_seconds = 1; -- unsigned int n_sleep = (max_sleep_seconds -- * 1000000 / sleep_microseconds); - int i; -- for (i = 0; i < n_sleep; i++) { -- if (i) -- usleep (sleep_microseconds); -- bool busy = false; -- int j; -- for (j = 0; j < lpn; j++) { -- if (!ok[j]) { -- ok[j] = remove_partition (disk, j + 1); -- errnums[j] = errno; -- if (!ok[j] && errnums[j] == EBUSY) -- busy = true; -+ /* remove old partitions first */ -+ for (i = 1; i <= lpn; i++) { -+ PedPartition *part = ped_disk_get_partition (disk, i); -+ if (part) { -+ unsigned long long length; -+ unsigned long long start; -+ /* get start and length of existing partition */ -+ if (get_partition_start_and_length(part, -+ &start, &length) -+ && start == part->geom.start -+ && length == part->geom.length) -+ { -+ ok[i - 1] = 1; -+ continue; -+ } - } -- } -- if (!busy) -- break; -- } -- -+ } - for (i = 1; i <= lpn; i++) { - PedPartition *part = ped_disk_get_partition (disk, i); - if (part) { -- if (!ok[i - 1] && errnums[i - 1] == EBUSY) { -- unsigned long long length; -- unsigned long long start; -- /* get start and length of existing partition */ -- if (!get_partition_start_and_length(part, -- &start, &length)) -- goto cleanup; -- if (start == part->geom.start -- && length == part->geom.length) -- ok[i - 1] = 1; -- /* If the new partition is unchanged and the -- existing one was not removed because it was -- in use, then reset the error flag and do not -- try to add it since it is already there. */ -+ unsigned long long length; -+ unsigned long long start; -+ /* get start and length of existing partition */ -+ if (get_partition_start_and_length(part, -+ &start, &length) -+ && start == part->geom.start -+ && length == part->geom.length) { -+ ok[i - 1] = 1; -+ /* partition is unchanged, so nothing to do */ - continue; - } -- -+ } -+ /* Attempt to remove the partition, retrying for -+ up to max_sleep_seconds upon any failure due to EBUSY. */ -+ unsigned int sleep_microseconds = 10000; -+ unsigned int max_sleep_seconds = 1; -+ unsigned int n_sleep = (max_sleep_seconds -+ * 1000000 / sleep_microseconds); -+ do { -+ ok[i - 1] = remove_partition (disk, i); -+ errnums[i - 1] = errno; -+ if (ok[i - 1] || errnums[i - 1] != EBUSY) -+ break; -+ usleep (sleep_microseconds); -+ } while (n_sleep--); -+ if (!ok[i - 1] && errnums[i - 1] == ENXIO) -+ ok[i - 1] = 1; /* it already doesn't exist */ -+ if (part && ok[i - 1]) { - /* add the (possibly modified or new) partition */ - if (!add_partition (disk, part)) { - ok[i - 1] = 0; --- -1.9.3 - diff --git a/0063-Fix-test-compilation.patch b/0063-Fix-test-compilation.patch deleted file mode 100644 index a365991..0000000 --- a/0063-Fix-test-compilation.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 02fc13fb6611b68d7d3275777f5674192b2f2bb5 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 17 Nov 2013 22:45:39 -0500 -Subject: [PATCH 063/131] Fix test compilation - -The tests were not being linked against libpthread but were using -it, and recent versions of gcc refuse to implicitly pull it in. ---- - libparted/tests/Makefile.am | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/libparted/tests/Makefile.am b/libparted/tests/Makefile.am -index bfa5790..12abe60 100644 ---- a/libparted/tests/Makefile.am -+++ b/libparted/tests/Makefile.am -@@ -10,7 +10,8 @@ AM_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS) - - LDADD = \ - $(top_builddir)/libparted/libparted.la \ -- $(CHECK_LIBS) -+ $(CHECK_LIBS) \ -+ -lpthread - - AM_CPPFLAGS = \ - $(CHECK_CFLAGS) \ --- -1.9.3 - diff --git a/0064-GPT-add-support-for-PReP-GUID.patch b/0064-GPT-add-support-for-PReP-GUID.patch deleted file mode 100644 index 72ed095..0000000 --- a/0064-GPT-add-support-for-PReP-GUID.patch +++ /dev/null @@ -1,210 +0,0 @@ -From d151cc20af79c89383ffacc89c1f646f831fc3e6 Mon Sep 17 00:00:00 2001 -From: Daniel Battaiola Kreling -Date: Mon, 7 Oct 2013 11:51:50 +0530 -Subject: [PATCH 064/131] GPT: add support for PReP GUID - -PReP (PowerPC Reference Platform) boot partition is the first partition used in -PowerPC platform for containing the bootable kernel or bootloader. The firmware -searches for this partition and jumps to it for booting. So far no GUID was -specified for this partition type and hence booting from GPT disk was not -supported on this platform. A new GUID 9e1a2d38-c612-4316-aa26-8b49521e5a8b for -PReP partition is proposed to be included in GPT. ---- - NEWS | 3 +++ - doc/parted.texi | 2 +- - libparted/labels/gpt.c | 38 ++++++++++++++++++++++++++++++++++++++ - 3 files changed, 42 insertions(+), 1 deletion(-) - -diff --git a/NEWS b/NEWS -index cb725e7..22e6109 100644 ---- a/NEWS -+++ b/NEWS -@@ -8,6 +8,9 @@ GNU parted NEWS -*- outline -*- - or are longer than the disk. This allows you to use parted to - repair the problem. - -+ Add support for prep flag to GPT to select PowerPC Reference Platform -+ boot partition type. -+ - ** Bug Fixes - - Avoid generating udev add/remove events for all unmodified partitions -diff --git a/doc/parted.texi b/doc/parted.texi -index 008c383..25a02c7 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -865,7 +865,7 @@ physical volume. - by the Linux/PA-RISC boot loader, palo. - - @item PREP --(MS-DOS) - this flag can be enabled so that the partition can be used -+(MS-DOS, GPT) - this flag can be enabled so that the partition can be used - as a PReP boot partition on PowerPC PReP or IBM RS6K/CHRP hardware. - - @item DIAG -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index bcf7812..66c96e6 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -146,6 +146,10 @@ typedef struct - ((efi_guid_t) { PED_CPU_TO_LE32 (0x5265636F), PED_CPU_TO_LE16 (0x7665), \ - PED_CPU_TO_LE16 (0x11AA), 0xaa, 0x11, \ - { 0x00, 0x30, 0x65, 0x43, 0xEC, 0xAC }}) -+#define PARTITION_PREP_GUID \ -+ ((efi_guid_t) { PED_CPU_TO_LE32 (0x9e1a2d38), PED_CPU_TO_LE16 (0xc612), \ -+ PED_CPU_TO_LE16 (0x4316), 0xaa, 0x26, \ -+ { 0x8b, 0x49, 0x52, 0x1e, 0x5a, 0x8b }}) - - struct __attribute__ ((packed)) _GuidPartitionTableHeader_t - { -@@ -289,6 +293,7 @@ typedef struct _GPTPartitionData - int atvrecv; - int msftrecv; - int legacy_boot; -+ int prep; - } GPTPartitionData; - - static PedDiskType gpt_disk_type; -@@ -803,6 +808,7 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->legacy_boot -+ = gpt_part_data->prep - = gpt_part_data->bios_grub = gpt_part_data->atvrecv = 0; - - if (pte->Attributes.RequiredToFunction & 0x1) -@@ -828,6 +834,8 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - gpt_part_data->msftrecv = 1; - else if (!guid_cmp (gpt_part_data->type, PARTITION_APPLE_TV_RECOVERY_GUID)) - gpt_part_data->atvrecv = 1; -+ else if (!guid_cmp (gpt_part_data->type, PARTITION_PREP_GUID)) -+ gpt_part_data->prep = 1; - - return part; - } -@@ -1344,6 +1352,7 @@ gpt_partition_new (const PedDisk *disk, - gpt_part_data->msftrecv = 0; - gpt_part_data->atvrecv = 0; - gpt_part_data->legacy_boot = 0; -+ gpt_part_data->prep = 0; - uuid_generate ((unsigned char *) &gpt_part_data->uuid); - swap_uuid_and_efi_guid ((unsigned char *) (&gpt_part_data->uuid)); - memset (gpt_part_data->name, 0, sizeof gpt_part_data->name); -@@ -1417,6 +1426,11 @@ gpt_partition_set_system (PedPartition *part, - gpt_part_data->type = PARTITION_RAID_GUID; - return 1; - } -+ if (gpt_part_data->prep) -+ { -+ gpt_part_data->type = PARTITION_PREP_GUID; -+ return 1; -+ } - if (gpt_part_data->boot) - { - gpt_part_data->type = PARTITION_SYSTEM_GUID; -@@ -1593,6 +1607,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftres - = gpt_part_data->msftdata - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_BIOS_GRUB: -@@ -1605,6 +1620,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftres - = gpt_part_data->msftdata - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_RAID: -@@ -1617,6 +1633,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftres - = gpt_part_data->msftdata - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_LVM: -@@ -1629,6 +1646,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftres - = gpt_part_data->msftdata - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_HPSERVICE: -@@ -1641,6 +1659,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftres - = gpt_part_data->msftdata - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_MSFT_RESERVED: -@@ -1653,6 +1672,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->hp_service - = gpt_part_data->msftdata - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_MSFT_DATA: -@@ -1665,6 +1685,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->hp_service - = gpt_part_data->msftres - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - gpt_part_data->msftdata = 1; - } else { -@@ -1681,6 +1702,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->hp_service - = gpt_part_data->msftdata - = gpt_part_data->msftres -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_APPLE_TV_RECOVERY: -@@ -1693,8 +1715,21 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->hp_service - = gpt_part_data->msftres - = gpt_part_data->msftdata -+ = gpt_part_data->prep - = gpt_part_data->msftrecv = 0; - return gpt_partition_set_system (part, part->fs_type); -+ case PED_PARTITION_PREP: -+ gpt_part_data->prep = state; -+ if (state) -+ gpt_part_data->boot -+ = gpt_part_data->raid -+ = gpt_part_data->lvm -+ = gpt_part_data->bios_grub -+ = gpt_part_data->hp_service -+ = gpt_part_data->msftres -+ = gpt_part_data->msftrecv -+ = gpt_part_data->atvrecv = 0; -+ return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_HIDDEN: - gpt_part_data->hidden = state; - return 1; -@@ -1741,6 +1776,8 @@ gpt_partition_get_flag (const PedPartition *part, PedPartitionFlag flag) - return gpt_part_data->hidden; - case PED_PARTITION_LEGACY_BOOT: - return gpt_part_data->legacy_boot; -+ case PED_PARTITION_PREP: -+ return gpt_part_data->prep; - case PED_PARTITION_SWAP: - case PED_PARTITION_LBA: - case PED_PARTITION_ROOT: -@@ -1767,6 +1804,7 @@ gpt_partition_is_flag_available (const PedPartition *part, - case PED_PARTITION_APPLE_TV_RECOVERY: - case PED_PARTITION_HIDDEN: - case PED_PARTITION_LEGACY_BOOT: -+ case PED_PARTITION_PREP: - return 1; - case PED_PARTITION_SWAP: - case PED_PARTITION_ROOT: --- -1.9.3 - diff --git a/0065-libparted-make-sure-not-to-treat-percentages-as-exac.patch b/0065-libparted-make-sure-not-to-treat-percentages-as-exac.patch deleted file mode 100644 index aa1e9eb..0000000 --- a/0065-libparted-make-sure-not-to-treat-percentages-as-exac.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 01900e056ec250836d15b5f5c3f59a8e1454b781 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Mon, 4 Nov 2013 13:10:09 -0500 -Subject: [PATCH 065/131] libparted: make sure not to treat percentages as - exact - -If 1% of the drive size worked out ot be an even power of -two, it would trigger the exact placement. Add an exception -for the percent units. ---- - NEWS | 4 ++++ - libparted/unit.c | 2 +- - 2 files changed, 5 insertions(+), 1 deletion(-) - -diff --git a/NEWS b/NEWS -index 22e6109..9d0d931 100644 ---- a/NEWS -+++ b/NEWS -@@ -13,6 +13,10 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ If a drive was 100 times an even multiple of two, sizes specified as -+ a percentage would trigger the exact placement rule and refuse to round -+ to the nearest half percent. -+ - Avoid generating udev add/remove events for all unmodified partitions - when writing a new table. - -diff --git a/libparted/unit.c b/libparted/unit.c -index e545985..ff479f1 100644 ---- a/libparted/unit.c -+++ b/libparted/unit.c -@@ -548,7 +548,7 @@ ped_unit_parse_custom (const char* str, const PedDevice* dev, PedUnit unit, - do not use 4MiB as the range. Rather, presume that they - are specifying precisely the starting or ending number, - and treat "4MiB" just as we would treat "4194304B". */ -- if (is_power_of_2 (unit_size)) -+ if (is_power_of_2 (unit_size) && unit != PED_UNIT_PERCENT) - radius = 0; - - *sector = num * unit_size / dev->sector_size; --- -1.9.3 - diff --git a/0066-bug-15591-PATCH-libparted-handle-i18n-gpt-partition-.patch b/0066-bug-15591-PATCH-libparted-handle-i18n-gpt-partition-.patch deleted file mode 100644 index 3f9fdde..0000000 --- a/0066-bug-15591-PATCH-libparted-handle-i18n-gpt-partition-.patch +++ /dev/null @@ -1,232 +0,0 @@ -From cf16ea884fc72aa99b49f721fc186429cec9fa87 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 22 Dec 2013 22:13:12 -0500 -Subject: [PATCH 066/131] bug#15591: [PATCH] libparted: handle i18n gpt - partition names correctly - -gpt.c was simply truncating the UTF-16 characters stored -in the partition name field to 8 bits. This corrupted non -ascii characters which later resulted in parted crashing in -strlist.c trying to convert the now invalid multi byte -characters to wchar. - -gpt.c will now properly convert the UTF-16 to the current -locale encoding. ---- - NEWS | 1 + - libparted/labels/gpt.c | 63 ++++++++++++++++++++++++++++++++++++++++------ - tests/Makefile.am | 1 + - tests/t0251-gpt-unicode.sh | 38 ++++++++++++++++++++++++++++ - 4 files changed, 96 insertions(+), 7 deletions(-) - create mode 100755 tests/t0251-gpt-unicode.sh - -diff --git a/NEWS b/NEWS -index 9d0d931..935fa33 100644 ---- a/NEWS -+++ b/NEWS -@@ -12,6 +12,7 @@ GNU parted NEWS -*- outline -*- - boot partition type. - - ** Bug Fixes -+ Fix gpt to correctly handle non ASCII charcters in partition names - - If a drive was 100 times an even multiple of two, sizes specified as - a percentage would trigger the exact placement rule and refuse to round -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 66c96e6..dce89b1 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -39,6 +39,8 @@ - #include - #include - #include -+#include -+#include - #include "xalloc.h" - #include "verify.h" - -@@ -196,7 +198,7 @@ struct __attribute__ ((packed)) _GuidPartitionEntry_t - uint64_t StartingLBA; - uint64_t EndingLBA; - GuidPartitionEntryAttributes_t Attributes; -- efi_char16_t PartitionName[72 / sizeof (efi_char16_t)]; -+ efi_char16_t PartitionName[36]; - }; - - #define GPT_PMBR_LBA 0 -@@ -281,7 +283,8 @@ typedef struct _GPTPartitionData - { - efi_guid_t type; - efi_guid_t uuid; -- char name[37]; -+ efi_char16_t name[37]; -+ char *translated_name; - int lvm; - int raid; - int boot; -@@ -797,10 +800,11 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - gpt_part_data = part->disk_specific; - gpt_part_data->type = pte->PartitionTypeGuid; - gpt_part_data->uuid = pte->UniquePartitionGuid; -- for (i = 0; i < 72 / sizeof (efi_char16_t); i++) -+ for (i = 0; i < 36; i++) - gpt_part_data->name[i] = - (efi_char16_t) PED_LE16_TO_CPU ((uint16_t) pte->PartitionName[i]); - gpt_part_data->name[i] = 0; -+ gpt_part_data->translated_name = 0; - - gpt_part_data->lvm = gpt_part_data->raid - = gpt_part_data->boot = gpt_part_data->hp_service -@@ -1210,7 +1214,7 @@ _partition_generate_part_entry (PedPartition *part, GuidPartitionEntry_t *pte) - if (gpt_part_data->legacy_boot) - pte->Attributes.LegacyBIOSBootable = 1; - -- for (i = 0; i < 72 / sizeof (efi_char16_t); i++) -+ for (i = 0; i < 36; i++) - pte->PartitionName[i] - = (efi_char16_t) PED_CPU_TO_LE16 ((uint16_t) gpt_part_data->name[i]); - } -@@ -1353,6 +1357,7 @@ gpt_partition_new (const PedDisk *disk, - gpt_part_data->atvrecv = 0; - gpt_part_data->legacy_boot = 0; - gpt_part_data->prep = 0; -+ gpt_part_data->translated_name = 0; - uuid_generate ((unsigned char *) &gpt_part_data->uuid); - swap_uuid_and_efi_guid ((unsigned char *) (&gpt_part_data->uuid)); - memset (gpt_part_data->name, 0, sizeof gpt_part_data->name); -@@ -1386,6 +1391,9 @@ gpt_partition_duplicate (const PedPartition *part) - goto error_free_part; - - *result_data = *part_data; -+ if (part_data->translated_name) -+ result_data->translated_name = xstrdup (part_data->translated_name); -+ else part_data->translated_name = 0; - return result; - - error_free_part: -@@ -1400,6 +1408,8 @@ gpt_partition_destroy (PedPartition *part) - if (part->type == 0) - { - PED_ASSERT (part->disk_specific != NULL); -+ GPTPartitionData *gpt_part_data = part->disk_specific; -+ free (gpt_part_data->translated_name); - free (part->disk_specific); - } - -@@ -1820,15 +1830,54 @@ gpt_partition_set_name (PedPartition *part, const char *name) - { - GPTPartitionData *gpt_part_data = part->disk_specific; - -- strncpy (gpt_part_data->name, name, 36); -- gpt_part_data->name[36] = 0; -+ free(gpt_part_data->translated_name); -+ gpt_part_data->translated_name = xstrdup(name); -+ iconv_t conv = iconv_open ("UTF-16", nl_langinfo (CODESET)); -+ if (conv == (iconv_t)-1) -+ goto err; -+ char *inbuff = gpt_part_data->translated_name; -+ char *outbuff = (char *)&gpt_part_data->name; -+ size_t inbuffsize = strlen (inbuff) + 1; -+ size_t outbuffsize = 72; -+ if (iconv (conv, &inbuff, &inbuffsize, &outbuff, &outbuffsize) == -1) -+ goto err; -+ iconv_close (conv); -+ return; -+ err: -+ ped_exception_throw (PED_EXCEPTION_WARNING, -+ PED_EXCEPTION_IGNORE, -+ _("Can not translate partition name")); -+ iconv_close (conv); - } - - static const char * - gpt_partition_get_name (const PedPartition *part) - { - GPTPartitionData *gpt_part_data = part->disk_specific; -- return gpt_part_data->name; -+ if (gpt_part_data->translated_name == NULL) -+ { -+ char buffer[200]; -+ iconv_t conv = iconv_open (nl_langinfo (CODESET), "UTF-16"); -+ if (conv == (iconv_t)-1) -+ goto err; -+ char *inbuff = (char *)&gpt_part_data->name; -+ char *outbuff = buffer; -+ size_t inbuffsize = 72; -+ size_t outbuffsize = sizeof(buffer); -+ if (iconv (conv, &inbuff, &inbuffsize, &outbuff, &outbuffsize) == -1) -+ goto err; -+ iconv_close (conv); -+ *outbuff = 0; -+ gpt_part_data->translated_name = xstrdup (buffer); -+ return gpt_part_data->translated_name; -+ err: -+ ped_exception_throw (PED_EXCEPTION_WARNING, -+ PED_EXCEPTION_IGNORE, -+ _("Can not translate partition name")); -+ iconv_close (conv); -+ return ""; -+ } -+ return gpt_part_data->translated_name; - } - - static int -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 16ec5d2..7a6fe8f 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -27,6 +27,7 @@ TESTS = \ - t0212-gpt-many-partitions.sh \ - t0220-gpt-msftres.sh \ - t0250-gpt.sh \ -+ t0251-gpt-unicode.sh \ - t0280-gpt-corrupt.sh \ - t0281-gpt-grow.sh \ - t0282-gpt-move-backup.sh \ -diff --git a/tests/t0251-gpt-unicode.sh b/tests/t0251-gpt-unicode.sh -new file mode 100755 -index 0000000..36a4c26 ---- /dev/null -+++ b/tests/t0251-gpt-unicode.sh -@@ -0,0 +1,38 @@ -+#!/bin/sh -+# Test unicode partition names -+# Copyright (C) 2013 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+ -+dev=loop-file -+ -+# create zeroed device -+truncate -s 10m $dev || fail=1 -+ -+export LC_ALL=en_US.UTF-8 -+# create gpt label with named partition -+part_name=$(printf 'foo\341\264\244') -+parted -s $dev mklabel gpt mkpart primary ext2 1MiB 2MiB name 1 $part_name > empty 2>&1 || fail=1 -+ -+# ensure there was no output -+compare /dev/null empty || fail=1 -+ -+# check for expected output -+dd if=$dev bs=1 skip=$(($sector_size_+$sector_size_+58)) count=10 2>/dev/null | od -An -tx1 > out || fail=1 -+echo ' 66 00 6f 00 6f 00 24 1d 00 00' >> exp -+compare exp out || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0067-Fix-help-text-for-disk_-set-toggle.patch b/0067-Fix-help-text-for-disk_-set-toggle.patch deleted file mode 100644 index 292d7cc..0000000 --- a/0067-Fix-help-text-for-disk_-set-toggle.patch +++ /dev/null @@ -1,98 +0,0 @@ -From 3e005b4644d2a97da85c251f93d32d93e94bcccf Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Mon, 24 Feb 2014 11:29:43 -0500 -Subject: [PATCH 067/131] Fix help text for disk_{set,toggle} - -Fix the help text to show *disk* flags instead of partition flags. ---- - NEWS | 4 ++++ - parted/parted.c | 23 +++++++++++++++++++++-- - 2 files changed, 25 insertions(+), 2 deletions(-) - -diff --git a/NEWS b/NEWS -index 935fa33..40ce370 100644 ---- a/NEWS -+++ b/NEWS -@@ -12,6 +12,10 @@ GNU parted NEWS -*- outline -*- - boot partition type. - - ** Bug Fixes -+ -+ Fix help text for disk_{set,toggle} to show *disk* flags instead -+ of partition flags. -+ - Fix gpt to correctly handle non ASCII charcters in partition names - - If a drive was 100 times an even multiple of two, sizes specified as -diff --git a/parted/parted.c b/parted/parted.c -index b20d432..a7d9363 100644 ---- a/parted/parted.c -+++ b/parted/parted.c -@@ -144,6 +144,7 @@ static const char* number_msg = N_( - - static const char* label_type_msg_start = N_("LABEL-TYPE is one of: "); - static const char* flag_msg_start = N_("FLAG is one of: "); -+static const char* disk_flag_msg_start = N_("FLAG is one of: "); - static const char* unit_msg_start = N_("UNIT is one of: "); - static const char* min_or_opt_msg = N_("desired alignment: minimum or optimal"); - static const char* part_type_msg = N_("PART-TYPE is one of: primary, logical, " -@@ -167,6 +168,7 @@ static const char* copyright_msg = N_( - - static char* label_type_msg; - static char* flag_msg; -+static char* disk_flag_msg; - static char* unit_msg; - - static char* mkpart_fs_type_msg; -@@ -1710,6 +1712,7 @@ _init_messages () - PedFileSystemAlias* fs_alias; - PedDiskType* disk_type; - PedPartitionFlag part_flag; -+ PedDiskFlag disk_flag; - PedUnit unit; - - /* flags */ -@@ -1728,6 +1731,22 @@ _init_messages () - - flag_msg = str_list_convert (list); - str_list_destroy (list); -+/* disk flags */ -+ first = 1; -+ list = str_list_create (_(disk_flag_msg_start), NULL); -+ for (disk_flag = ped_disk_flag_next (0); disk_flag; -+ disk_flag = ped_disk_flag_next (disk_flag)) { -+ if (first) -+ first = 0; -+ else -+ str_list_append (list, ", "); -+ str_list_append (list, -+ _(ped_disk_flag_get_name (disk_flag))); -+ } -+ str_list_append (list, "\n"); -+ -+ disk_flag_msg = str_list_convert (list); -+ str_list_destroy (list); - - /* units */ - first = 1; -@@ -1912,7 +1931,7 @@ command_register (commands, command_create ( - str_list_create ( - _("disk_set FLAG STATE change the FLAG on selected device"), - NULL), -- str_list_create (flag_msg, _(state_msg), NULL), 1)); -+ str_list_create (disk_flag_msg, _(state_msg), NULL), 1)); - - command_register (commands, command_create ( - str_list_create_unique ("disk_toggle", _("disk_toggle"), NULL), -@@ -1921,7 +1940,7 @@ command_register (commands, command_create ( - _("disk_toggle [FLAG] toggle the state of FLAG on " - "selected device"), - NULL), -- str_list_create (flag_msg, NULL), 1)); -+ str_list_create (disk_flag_msg, NULL), 1)); - - command_register (commands, command_create ( - str_list_create_unique ("set", _("set"), NULL), --- -1.9.3 - diff --git a/0068-libparted-copy-pmbr_boot-when-duplicating-GPT-disk.patch b/0068-libparted-copy-pmbr_boot-when-duplicating-GPT-disk.patch deleted file mode 100644 index 8d2f58a..0000000 --- a/0068-libparted-copy-pmbr_boot-when-duplicating-GPT-disk.patch +++ /dev/null @@ -1,25 +0,0 @@ -From c261a9b340e2982a49e055ea6332fd0f49f3d531 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:24:51 -0700 -Subject: [PATCH 068/131] libparted: copy pmbr_boot when duplicating GPT disk - -* libparted/labels/gpt.c (gpt_duplicate): copy pmbr_boot flag ---- - libparted/labels/gpt.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index dce89b1..6fd8880 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -566,6 +566,7 @@ gpt_duplicate (const PedDisk *disk) - old_disk_data->data_area.length); - new_disk_data->entry_count = old_disk_data->entry_count; - new_disk_data->uuid = old_disk_data->uuid; -+ new_disk_data->pmbr_boot = old_disk_data->pmbr_boot; - return new_disk; - } - --- -1.9.3 - diff --git a/0069-tests-test-creating-20-device-mapper-partitions-8031.patch b/0069-tests-test-creating-20-device-mapper-partitions-8031.patch deleted file mode 100644 index 4eb7bc4..0000000 --- a/0069-tests-test-creating-20-device-mapper-partitions-8031.patch +++ /dev/null @@ -1,95 +0,0 @@ -From d19d16357aff6bff634ad134597c0626c21496ac Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:24:52 -0700 -Subject: [PATCH 069/131] tests: test creating 20 device-mapper partitions - (#803108) - -* tests/t6004-dm-many-partitions.sh: Make sure > 17 partitions appear in - device mapper. ---- - tests/Makefile.am | 1 + - tests/t6004-dm-many-partitions.sh | 60 +++++++++++++++++++++++++++++++++++++++ - 2 files changed, 61 insertions(+) - create mode 100755 tests/t6004-dm-many-partitions.sh - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 7a6fe8f..13fdde5 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -64,6 +64,7 @@ TESTS = \ - t6001-psep.sh \ - t6002-dm-busy.sh \ - t6003-dm-hide.sh \ -+ t6004-dm-many-partitions.sh \ - t6100-mdraid-partitions.sh \ - t7000-scripting.sh \ - t8000-loop.sh \ -diff --git a/tests/t6004-dm-many-partitions.sh b/tests/t6004-dm-many-partitions.sh -new file mode 100755 -index 0000000..4d08e72 ---- /dev/null -+++ b/tests/t6004-dm-many-partitions.sh -@@ -0,0 +1,60 @@ -+#!/bin/sh -+# device-mapper: create many partitions -+# This would not create partitions > 16 when using device-mapper -+ -+# Copyright (C) 2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+ -+require_root_ -+(dmsetup --help) > /dev/null 2>&1 || skip_test_ "No dmsetup installed" -+ -+ss=$sector_size_ -+ns=300 -+n_partitions=20 -+start_sector=34 -+loop_file=loop-file-$$ -+dm_name=dm-test-$$ -+ -+cleanup_() { -+ dmsetup remove $dm_name -+ test -n "$dev" && losetup -d "$dev" -+ rm -f $loop_file; -+} -+ -+# create a file large enough to hold a GPT partition table -+dd if=/dev/null of=$loop_file bs=$ss seek=$ns || framework_failure -+dev=$(losetup --show -f $loop_file) || framework_failure -+dmsetup create $dm_name --table "0 $ns linear $dev 0" || framework_failure -+ -+cmd= -+for ((i=1; i<=$n_partitions; i+=1)); do -+ s=$((start_sector + i - 1)) -+ cmd="$cmd mkpart p$i ${s}s ${s}s" -+done -+parted -m -a min -s /dev/mapper/$dm_name mklabel gpt $cmd > /dev/null 2>&1 || fail=1 -+ -+# Make sure all the partitions appeared under /dev/mapper/ -+for ((i=1; i<=$n_partitions; i+=1)); do -+ if [ ! -e "/dev/mapper/${dm_name}p$i" ]; then -+ fail=1 -+ break -+ fi -+ # remove the partitions as we go, otherwise cleanup won't work. -+ dmsetup remove /dev/mapper/${dm_name}p$i -+done -+ -+Exit $fail --- -1.9.3 - diff --git a/0070-libparted-use-dm_udev_wait-698121.patch b/0070-libparted-use-dm_udev_wait-698121.patch deleted file mode 100644 index 51f966a..0000000 --- a/0070-libparted-use-dm_udev_wait-698121.patch +++ /dev/null @@ -1,140 +0,0 @@ -From 60fe959e1446337c3455656daad2c2b7114a1dcd Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:24:53 -0700 -Subject: [PATCH 070/131] libparted: use dm_udev_wait (#698121) - -This is based on Peter Rajnoha's patch to use dm_udev_wait to -synchronize with udev. - -This requires libdevmapper v1.02.39 and higher. - -mailing list thread: -https://lists.gnu.org/archive/html/bug-parted/2010-09/msg00007.html - -* libparted/arch/linux.c (_dm_task_run_wait): New function -(_is_dm_major): Add cookie and change call to _dm_task_run_wait -(_is_dmraid_device): Same -(_dm_is_part): Same -(dm_canonical_path): Same -(_dm_remove_partition): Same -(_dm_get_partition_start_and_length): Same -(_dm_add_partition): Same -(linux_new): Enable udev sync support ---- - NEWS | 5 +++++ - libparted/arch/linux.c | 42 +++++++++++++++++++++++++++++------------- - 2 files changed, 34 insertions(+), 13 deletions(-) - -diff --git a/NEWS b/NEWS -index 40ce370..9f51f85 100644 ---- a/NEWS -+++ b/NEWS -@@ -13,6 +13,11 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: On multipath systems new partitions would sometimes not -+ appear, reporting 'device-mapper: create ioctl failed: Device or -+ resource busy' until the system was rebooted. Added dm_udev_wait -+ calls to synchronize parted with udev. -+ - Fix help text for disk_{set,toggle} to show *disk* flags instead - of partition flags. - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index f43eae1..452ea7f 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -438,6 +438,17 @@ _is_virtblk_major (int major) - - #ifdef ENABLE_DEVICE_MAPPER - static int -+_dm_task_run_wait (struct dm_task *task, uint32_t cookie) -+{ -+ int rc = 0; -+ -+ rc = dm_task_run (task); -+ dm_udev_wait (cookie); -+ -+ return rc; -+} -+ -+static int - _is_dm_major (int major) - { - return _major_type_in_devices (major, "device-mapper"); -@@ -1385,6 +1396,10 @@ linux_new (const char* path) - dev->dirty = 0; - dev->boot_dirty = 0; - -+#ifdef ENABLE_DEVICE_MAPPER -+ dm_udev_set_sync_support(1); -+#endif -+ - if (!_device_probe_type (dev)) - goto error_free_arch_specific; - -@@ -2631,31 +2646,29 @@ _device_get_partition_range(PedDevice const* dev) - static int - _dm_remove_partition(PedDisk* disk, int partno) - { -- int rc; -+ int rc = 0; -+ uint32_t cookie = 0; - char *part_name = _device_get_part_path (disk->dev, partno); - - int fd = open (part_name, O_RDONLY | O_EXCL); - if (fd == -1) { - if (errno == ENOENT) - errno = ENXIO; /* nothing to remove, device already doesn't exist */ -- free (part_name); -- return 0; -+ goto err; - } - close (fd); - struct dm_task *task = dm_task_create(DM_DEVICE_REMOVE); -- if (!task) { -- free (part_name); -- return 0; -- } -+ if (!task) -+ goto err; - dm_task_set_name (task, part_name); -- rc = dm_task_run(task); -+ if (!dm_task_set_cookie (task, &cookie, 0)) -+ goto err; -+ rc = _dm_task_run_wait (task, cookie); - dm_task_update_nodes(); - dm_task_destroy(task); -+err: - free (part_name); -- if (!rc) -- return 0; -- -- return 1; -+ return rc; - } - - static bool -@@ -2699,6 +2712,7 @@ _dm_add_partition (PedDisk* disk, const PedPartition* part) - LinuxSpecific* arch_specific = LINUX_SPECIFIC (disk->dev); - char *params = NULL; - char *vol_name = NULL; -+ uint32_t cookie = 0; - - /* Get map name from devicemapper */ - struct dm_task *task = dm_task_create (DM_DEVICE_INFO); -@@ -2735,7 +2749,9 @@ _dm_add_partition (PedDisk* disk, const PedPartition* part) - dm_task_set_name (task, vol_name); - dm_task_add_target (task, 0, part->geom.length, - "linear", params); -- if (dm_task_run (task)) { -+ if (!dm_task_set_cookie (task, &cookie, 0)) -+ goto err; -+ if (_dm_task_run_wait (task, cookie)) { - dm_task_update_nodes (); - dm_task_destroy (task); - free (params); --- -1.9.3 - diff --git a/0071-libparted-preserve-the-uuid-on-dm-partitions-832145.patch b/0071-libparted-preserve-the-uuid-on-dm-partitions-832145.patch deleted file mode 100644 index 2b7f132..0000000 --- a/0071-libparted-preserve-the-uuid-on-dm-partitions-832145.patch +++ /dev/null @@ -1,81 +0,0 @@ -From 39e38c0a4c0f3ad0e029792e0ddee9761b956c1e Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:24:54 -0700 -Subject: [PATCH 071/131] libparted: preserve the uuid on dm partitions - (#832145) - -* libparted/arch/linux.c (_dm_add_partition): Set the uuid if there was - one. ---- - libparted/arch/linux.c | 20 ++++++++++++++++---- - 1 file changed, 16 insertions(+), 4 deletions(-) - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 452ea7f..4376d17 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2710,9 +2710,12 @@ static int - _dm_add_partition (PedDisk* disk, const PedPartition* part) - { - LinuxSpecific* arch_specific = LINUX_SPECIFIC (disk->dev); -- char *params = NULL; -- char *vol_name = NULL; -- uint32_t cookie = 0; -+ char* params = NULL; -+ char* vol_name = NULL; -+ const char* dev_name = NULL; -+ char* vol_uuid = NULL; -+ const char* dev_uuid = NULL; -+ uint32_t cookie = 0; - - /* Get map name from devicemapper */ - struct dm_task *task = dm_task_create (DM_DEVICE_INFO); -@@ -2726,7 +2729,7 @@ _dm_add_partition (PedDisk* disk, const PedPartition* part) - if (!dm_task_run(task)) - goto err; - -- const char *dev_name = dm_task_get_name (task); -+ dev_name = dm_task_get_name (task); - size_t name_len = strlen (dev_name); - vol_name = zasprintf ("%s%s%d", - dev_name, -@@ -2735,6 +2738,11 @@ _dm_add_partition (PedDisk* disk, const PedPartition* part) - if (vol_name == NULL) - goto err; - -+ dev_uuid = dm_task_get_uuid (task); -+ if (dev_uuid && (strlen(dev_uuid) > 0) -+ && !(vol_uuid = zasprintf ("part%d-%s", part->num, dev_uuid))) -+ goto err; -+ - /* Caution: dm_task_destroy frees dev_name. */ - dm_task_destroy (task); - task = NULL; -@@ -2747,6 +2755,8 @@ _dm_add_partition (PedDisk* disk, const PedPartition* part) - goto err; - - dm_task_set_name (task, vol_name); -+ if (vol_uuid) -+ dm_task_set_uuid (task, vol_uuid); - dm_task_add_target (task, 0, part->geom.length, - "linear", params); - if (!dm_task_set_cookie (task, &cookie, 0)) -@@ -2755,6 +2765,7 @@ _dm_add_partition (PedDisk* disk, const PedPartition* part) - dm_task_update_nodes (); - dm_task_destroy (task); - free (params); -+ free (vol_uuid); - free (vol_name); - return 1; - } else { -@@ -2765,6 +2776,7 @@ err: - if (task) - dm_task_destroy (task); - free (params); -+ free (vol_uuid); - free (vol_name); - return 0; - } --- -1.9.3 - diff --git a/0072-tests-Make-sure-dm-UUIDs-are-not-erased.patch b/0072-tests-Make-sure-dm-UUIDs-are-not-erased.patch deleted file mode 100644 index c3947ff..0000000 --- a/0072-tests-Make-sure-dm-UUIDs-are-not-erased.patch +++ /dev/null @@ -1,91 +0,0 @@ -From a963cd53ab1f14ef7f9a9b84a2536103ad690479 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:24:55 -0700 -Subject: [PATCH 072/131] tests: Make sure dm UUIDs are not erased - -* tests/t6005-dm-uuid.sh: Make sure dm UUIDs are not erased ---- - tests/Makefile.am | 1 + - tests/t6005-dm-uuid.sh | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 59 insertions(+) - create mode 100755 tests/t6005-dm-uuid.sh - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 13fdde5..9100a81 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -65,6 +65,7 @@ TESTS = \ - t6002-dm-busy.sh \ - t6003-dm-hide.sh \ - t6004-dm-many-partitions.sh \ -+ t6005-dm-uuid.sh \ - t6100-mdraid-partitions.sh \ - t7000-scripting.sh \ - t8000-loop.sh \ -diff --git a/tests/t6005-dm-uuid.sh b/tests/t6005-dm-uuid.sh -new file mode 100755 -index 0000000..f58cb06 ---- /dev/null -+++ b/tests/t6005-dm-uuid.sh -@@ -0,0 +1,58 @@ -+#!/bin/sh -+# device-mapper: preserve uuid -+# The dm's partitions uuid would be removed when creating new partitions -+ -+# Copyright (C) 2012 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+ -+require_root_ -+(dmsetup --help) > /dev/null 2>&1 || skip_test_ "No dmsetup installed" -+ -+ss=$sector_size_ -+ns=300 -+n_partitions=3 -+start_sector=34 -+loop_file=loop-file-$$ -+dm_name=dm-test-$$ -+ -+cleanup_() { -+ dmsetup remove $dm_name -+ test -n "$dev" && losetup -d "$dev" -+ rm -f $loop_file; -+} -+ -+# create a file large enough to hold a GPT partition table -+dev=$(loop_setup_ $loop_file) || framework_failure -+dmsetup create $dm_name --table "0 $ns linear $dev 0" || framework_failure -+dmsetup rename $dm_name --setuuid f139317b-f98a-45d7-ab3b-9b4e0a336872 || framework_failure -+ -+cmd= -+for ((i=1; i<=$n_partitions; i+=1)); do -+ s=$((start_sector + i - 1)) -+ cmd="$cmd mkpart p$i ${s}s ${s}s" -+done -+parted -m -a min -s /dev/mapper/$dm_name mklabel gpt $cmd > /dev/null 2>&1 || fail=1 -+ -+# Make sure all the partitions have UUIDs -+for ((i=1; i<=$n_partitions; i+=1)); do -+ dmsetup info /dev/mapper/${dm_name}p$i | grep UUID || fail=1 -+ -+ # remove the partitions as we go, otherwise cleanup won't work. -+ dmsetup remove /dev/mapper/${dm_name}p$i -+done -+ -+Exit $fail --- -1.9.3 - diff --git a/0073-libparted-don-t-canonicalize-dev-md-paths-872361.patch b/0073-libparted-don-t-canonicalize-dev-md-paths-872361.patch deleted file mode 100644 index 97be34a..0000000 --- a/0073-libparted-don-t-canonicalize-dev-md-paths-872361.patch +++ /dev/null @@ -1,54 +0,0 @@ -From 7be35be5de01fa90f23810fb66efc3ccdbe5679a Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:25:01 -0700 -Subject: [PATCH 073/131] libparted: don't canonicalize /dev/md/ paths - (#872361) - -This is the same issue we have with /dev/mapper/ paths that was fixed in -commit c1eb485b9fd8919e18f192d678bc52b0488e6ee0. When libparted -is used to setup the device the symlink should be used to reference it, -not the backing device name which could change. - -* libparted/device.c (ped_device_get): Don't canonicalize names - that start with "/dev/md/". ---- - NEWS | 4 ++++ - libparted/device.c | 7 +++++-- - 2 files changed, 9 insertions(+), 2 deletions(-) - -diff --git a/NEWS b/NEWS -index 9f51f85..74b7697 100644 ---- a/NEWS -+++ b/NEWS -@@ -13,6 +13,10 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: /dev/md/ symlink can change after libparted dereferences it, -+ instead it should just use the symlink as given by the caller in the -+ same way we do with /dev/mapper/. -+ - libparted: On multipath systems new partitions would sometimes not - appear, reporting 'device-mapper: create ioctl failed: Device or - resource busy' until the system was rebooted. Added dm_udev_wait -diff --git a/libparted/device.c b/libparted/device.c -index 738b320..cdcc117 100644 ---- a/libparted/device.c -+++ b/libparted/device.c -@@ -152,8 +152,11 @@ ped_device_get (const char* path) - char* normal_path = NULL; - - PED_ASSERT (path != NULL); -- /* Don't canonicalize /dev/mapper paths, see tests/symlink.c */ -- if (strncmp (path, "/dev/mapper/", 12)) -+ /* Don't canonicalize /dev/mapper or /dev/md/ paths, see -+ tests/symlink.c -+ */ -+ if (strncmp (path, "/dev/mapper/", 12) && -+ strncmp (path, "/dev/md/", 8)) - normal_path = canonicalize_file_name (path); - if (!normal_path) - /* Well, maybe it is just that the file does not exist. --- -1.9.3 - diff --git a/0074-tests-rewrite-t6001-to-use-dev-mapper.patch b/0074-tests-rewrite-t6001-to-use-dev-mapper.patch deleted file mode 100644 index 9ec3e25..0000000 --- a/0074-tests-rewrite-t6001-to-use-dev-mapper.patch +++ /dev/null @@ -1,92 +0,0 @@ -From 6a3194bf13d23c4e7fcc346f7188060d50f3cedc Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:25:02 -0700 -Subject: [PATCH 074/131] tests: rewrite t6001 to use /dev/mapper - -This test began failing because using a private copy of /dev/mapper -confuses the system. This fixes that and generally cleans up the test. - -tests/t6001.sh: update to use /dev/mapper directly ---- - tests/t6001-psep.sh | 42 +++++++++++++++++------------------------- - 1 file changed, 17 insertions(+), 25 deletions(-) - -diff --git a/tests/t6001-psep.sh b/tests/t6001-psep.sh -index da6b8a1..809ff9e 100644 ---- a/tests/t6001-psep.sh -+++ b/tests/t6001-psep.sh -@@ -19,10 +19,7 @@ - . "${srcdir=.}/init.sh"; path_prepend_ ../parted - - require_root_ --lvm_init_root_dir_ -- --test "x$ENABLE_DEVICE_MAPPER" = xyes \ -- || skip_ "no device-mapper support" -+(dmsetup --help) > /dev/null 2>&1 || skip_test_ "No dmsetup installed" - - # Device maps names - should be random to not conflict with existing ones on - # the system -@@ -41,25 +38,19 @@ cleanup_fn_() { - rm -f "$f1 $f2"; - } - --# create a file of size N bytes --N=10M -- --f1=$(pwd)/1; d1=$(loop_setup_ "$f1") \ -- || skip_ "is this partition mounted with 'nodev'?" -+loop_file_1=loop-file-1-$$ -+loop_file_2=loop-file-2-$$ - --f2=$(pwd)/2 ;d2=$(loop_setup_ "$f2") \ -- || skip_ "is this partition mounted with 'nodev'?" -+d1=$(loop_setup_ $loop_file_1) || framework_failure -+d1_size=$(blockdev --getsz $d1) -+d2=$(loop_setup_ $loop_file_2) || framework_failure -+d2_size=$(blockdev --getsz $d2) - --dmsetup_cmd="0 `blockdev --getsz $d1` linear $d1 0" --# setup: create a mapping --echo "$dmsetup_cmd" | dmsetup create "$linear_" || fail=1 --dev="$DM_DEV_DIR/mapper/$linear_" -+dmsetup create $linear_ --table "0 $d1_size linear $d1 0" || framework_failure -+dev="/dev/mapper/$linear_" - - # Create msdos partition table --parted -s $dev mklabel msdos > out 2>&1 || fail=1 --compare /dev/null out || fail=1 -- --parted -s $dev mkpart primary fat32 1m 5m > out 2>&1 || fail=1 -+parted -s $dev mklabel msdos mkpart primary fat32 1m 5m > out 2>&1 || fail=1 - compare /dev/null out || fail=1 - - #make sure device name is correct -@@ -67,17 +58,18 @@ test -e ${dev}p1 || fail=1 - - #repeat on name not ending in a digit - # setup: create a mapping --echo "$dmsetup_cmd" | dmsetup create "$linear2_" || fail=1 --dev="$DM_DEV_DIR/mapper/$linear2_" -+dmsetup create $linear2_ --table "0 $d2_size linear $d2 0" || framework_failure -+dev="/dev/mapper/$linear2_" - - # Create msdos partition table --parted -s $dev mklabel msdos > out 2>&1 || fail=1 --compare /dev/null out || fail=1 -- --parted -s $dev mkpart primary fat32 1m 5m > out 2>&1 || fail=1 -+parted -s $dev mklabel msdos mkpart primary fat32 1m 5m > out 2>&1 || fail=1 - compare /dev/null out || fail=1 - - #make sure device name is correct - test -e ${dev}1 || fail=1 - -+if [ -n "$fail" ]; then -+ ls /dev/mapper -+fi -+ - Exit $fail --- -1.9.3 - diff --git a/0075-libparted-Add-Intel-Rapid-Start-Technology-partition.patch b/0075-libparted-Add-Intel-Rapid-Start-Technology-partition.patch deleted file mode 100644 index 484626e..0000000 --- a/0075-libparted-Add-Intel-Rapid-Start-Technology-partition.patch +++ /dev/null @@ -1,384 +0,0 @@ -From 4d0cd271069997e7d44ed3b52426ccf2570048c8 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:25:03 -0700 -Subject: [PATCH 075/131] libparted: Add Intel Rapid Start Technology partition - flag. - -This adds support for the irst partition type flag. Sets the type to -0x84 on MS-DOS and D3BFE2DE-3DAF-11DF-BA-40-E3A556D89593 on GPT. - -* NEWS (New Features): Mention it. -* doc/C/parted.8: Document irst flag. -* doc/parted.texti: Document irst flag. -* include/parted/disk.in.h (_PedPartitionFlag): Add PED_PARTITION_IRST flag -* libparted/disk.c (ped_partition_flag_get_name): Add irst flag -* libparted/labels/dos.c (DosPartitionData): Likewise -(raw_part_parse): Likewise -(msdos_partition_new): Likewise -(msdos_partition_duplicate): Likewise -(msdos_partition_set_system): Likewise -(clear_flags): Likewise -(msdos_partition_set_flag): Likewise -(msdos_partition_get_flag): Likewise -(msdos_partition_is_flag_available): Likewise -* libparted/labels/gpt.c: Add PARTITION_IRST_GUID -(GPTPartitionData): Add irst flag -(_parse_part_entry): Likewise -(gpt_partition_new): Likewise -(gpt_partition_set_system): Likewise -(gpt_partition_set_flag): Likewise -(gpt_partition_get_flag): Likewise -(gpt_partition_is_flag_available): Likewise ---- - NEWS | 4 ++++ - doc/C/parted.8 | 2 +- - doc/parted.texi | 4 ++++ - include/parted/disk.in.h | 5 +++-- - libparted/disk.c | 2 ++ - libparted/labels/dos.c | 21 +++++++++++++++++++++ - libparted/labels/gpt.c | 40 ++++++++++++++++++++++++++++++++++++++++ - 7 files changed, 75 insertions(+), 3 deletions(-) - -diff --git a/NEWS b/NEWS -index 74b7697..27710b6 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,10 @@ GNU parted NEWS -*- outline -*- - - ** New Features - -+ Added new partition type flag, irst, for use with Intel Rapid Start -+ Technology. On MS-DOS disk labels it sets the type to 0x84 and on GPT -+ it sets the GUID to D3BFE2DE-3DAF-11DF-BA-40-E3A556D89593. -+ - You can now choose to ignore errors about partitions that overlap, - or are longer than the disk. This allows you to use parted to - repair the problem. -diff --git a/doc/C/parted.8 b/doc/C/parted.8 -index a9f73f5..2f8e9f5 100644 ---- a/doc/C/parted.8 -+++ b/doc/C/parted.8 -@@ -104,7 +104,7 @@ or an LVM logical volume if necessary. - .B set \fIpartition\fP \fIflag\fP \fIstate\fP - Change the state of the \fIflag\fP on \fIpartition\fP to \fIstate\fP. - Supported flags are: "boot", "root", "swap", "hidden", "raid", "lvm", "lba", --"legacy_boot" and "palo". -+"legacy_boot", "irst" and "palo". - \fIstate\fP should be either "on" or "off". - .TP - .B unit \fIunit\fP -diff --git a/doc/parted.texi b/doc/parted.texi -index 25a02c7..4c63fe3 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -836,6 +836,10 @@ used by Windows on GPT disks. Note that this flag should not normally be - set on Windows filesystem partitions (those that contain NTFS or FAT - filesystems). - -+@item irst -+(MS-DOS, GPT) - this flag identifies an Intel Rapid Start Technology -+partition. -+ - @item lba - (MS-DOS) - this flag can be enabled to tell MS DOS, MS Windows 9x and - MS Windows ME based operating systems to use Linear (LBA) mode. -diff --git a/include/parted/disk.in.h b/include/parted/disk.in.h -index aa905c5..585383d 100644 ---- a/include/parted/disk.in.h -+++ b/include/parted/disk.in.h -@@ -73,10 +73,11 @@ enum _PedPartitionFlag { - PED_PARTITION_APPLE_TV_RECOVERY=13, - PED_PARTITION_DIAG=14, - PED_PARTITION_LEGACY_BOOT=15, -- PED_PARTITION_MSFT_DATA=16 -+ PED_PARTITION_MSFT_DATA=16, -+ PED_PARTITION_IRST=17 - }; - #define PED_PARTITION_FIRST_FLAG PED_PARTITION_BOOT --#define PED_PARTITION_LAST_FLAG PED_PARTITION_MSFT_DATA -+#define PED_PARTITION_LAST_FLAG PED_PARTITION_IRST - - enum _PedDiskTypeFeature { - PED_DISK_TYPE_EXTENDED=1, /**< supports extended partitions */ -diff --git a/libparted/disk.c b/libparted/disk.c -index ce71bfc..18c94ac 100644 ---- a/libparted/disk.c -+++ b/libparted/disk.c -@@ -2402,6 +2402,8 @@ ped_partition_flag_get_name (PedPartitionFlag flag) - return N_("diag"); - case PED_PARTITION_LEGACY_BOOT: - return N_("legacy_boot"); -+ case PED_PARTITION_IRST: -+ return N_("irst"); - - default: - ped_exception_throw ( -diff --git a/libparted/labels/dos.c b/libparted/labels/dos.c -index 6bddd79..c754970 100644 ---- a/libparted/labels/dos.c -+++ b/libparted/labels/dos.c -@@ -85,6 +85,7 @@ static const char MBR_BOOT_CODE[] = { - #define PARTITION_LDM 0x42 - #define PARTITION_LINUX_SWAP 0x82 - #define PARTITION_LINUX 0x83 -+#define PARTITION_IRST 0x84 - #define PARTITION_LINUX_EXT 0x85 - #define PARTITION_LINUX_LVM 0x8e - #define PARTITION_HFS 0xaf -@@ -159,6 +160,7 @@ typedef struct { - int palo; - int prep; - int diag; -+ int irst; - OrigState* orig; /* used for CHS stuff */ - } DosPartitionData; - -@@ -924,6 +926,7 @@ raw_part_parse (const PedDisk* disk, const DosRawPartition* raw_part, - dos_data->lba = raw_part_is_lba (raw_part); - dos_data->palo = raw_part->type == PARTITION_PALO; - dos_data->prep = raw_part->type == PARTITION_PREP; -+ dos_data->irst = raw_part->type == PARTITION_IRST; - dos_data->orig = ped_malloc (sizeof (OrigState)); - if (!dos_data->orig) { - ped_partition_destroy (part); -@@ -1316,6 +1319,7 @@ msdos_partition_new (const PedDisk* disk, PedPartitionType part_type, - dos_data->lba = 0; - dos_data->palo = 0; - dos_data->prep = 0; -+ dos_data->irst = 0; - } else { - part->disk_specific = NULL; - } -@@ -1351,6 +1355,7 @@ msdos_partition_duplicate (const PedPartition* part) - new_dos_data->lba = old_dos_data->lba; - new_dos_data->palo = old_dos_data->palo; - new_dos_data->prep = old_dos_data->prep; -+ new_dos_data->irst = old_dos_data->irst; - - if (old_dos_data->orig) { - new_dos_data->orig = ped_malloc (sizeof (OrigState)); -@@ -1399,6 +1404,7 @@ msdos_partition_set_system (PedPartition* part, - dos_data->lvm = 0; - dos_data->palo = 0; - dos_data->prep = 0; -+ dos_data->irst = 0; - if (dos_data->lba) - dos_data->system = PARTITION_EXT_LBA; - else -@@ -1431,6 +1437,10 @@ msdos_partition_set_system (PedPartition* part, - dos_data->system = PARTITION_PREP; - return 1; - } -+ if (dos_data->irst) { -+ dos_data->system = PARTITION_IRST; -+ return 1; -+ } - - if (!fs_type) - dos_data->system = PARTITION_LINUX; -@@ -1467,6 +1477,7 @@ clear_flags (DosPartitionData *dos_data) - dos_data->lvm = 0; - dos_data->palo = 0; - dos_data->prep = 0; -+ dos_data->irst = 0; - dos_data->raid = 0; - } - -@@ -1545,6 +1556,12 @@ msdos_partition_set_flag (PedPartition* part, - dos_data->prep = state; - return ped_partition_set_system (part, part->fs_type); - -+ case PED_PARTITION_IRST: -+ if (state) -+ clear_flags (dos_data); -+ dos_data->irst = state; -+ return ped_partition_set_system (part, part->fs_type); -+ - default: - return 0; - } -@@ -1587,6 +1604,9 @@ msdos_partition_get_flag (const PedPartition* part, PedPartitionFlag flag) - case PED_PARTITION_PREP: - return dos_data->prep; - -+ case PED_PARTITION_IRST: -+ return dos_data->irst; -+ - default: - return 0; - } -@@ -1609,6 +1629,7 @@ msdos_partition_is_flag_available (const PedPartition* part, - case PED_PARTITION_LBA: - case PED_PARTITION_PALO: - case PED_PARTITION_PREP: -+ case PED_PARTITION_IRST: - case PED_PARTITION_DIAG: - return 1; - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 6fd8880..ff87708 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -152,6 +152,10 @@ typedef struct - ((efi_guid_t) { PED_CPU_TO_LE32 (0x9e1a2d38), PED_CPU_TO_LE16 (0xc612), \ - PED_CPU_TO_LE16 (0x4316), 0xaa, 0x26, \ - { 0x8b, 0x49, 0x52, 0x1e, 0x5a, 0x8b }}) -+#define PARTITION_IRST_GUID \ -+ ((efi_guid_t) { PED_CPU_TO_LE32 (0xD3BFE2DE), PED_CPU_TO_LE16 (0x3DAF), \ -+ PED_CPU_TO_LE16 (0x11DF), 0xba, 0x40, \ -+ { 0xE3, 0xA5, 0x56, 0xD8, 0x95, 0x93 }}) - - struct __attribute__ ((packed)) _GuidPartitionTableHeader_t - { -@@ -297,6 +301,7 @@ typedef struct _GPTPartitionData - int msftrecv; - int legacy_boot; - int prep; -+ int irst; - } GPTPartitionData; - - static PedDiskType gpt_disk_type; -@@ -814,6 +819,7 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - = gpt_part_data->msftrecv - = gpt_part_data->legacy_boot - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->bios_grub = gpt_part_data->atvrecv = 0; - - if (pte->Attributes.RequiredToFunction & 0x1) -@@ -841,6 +847,8 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - gpt_part_data->atvrecv = 1; - else if (!guid_cmp (gpt_part_data->type, PARTITION_PREP_GUID)) - gpt_part_data->prep = 1; -+ else if (!guid_cmp (gpt_part_data->type, PARTITION_IRST_GUID)) -+ gpt_part_data->irst = 1; - - return part; - } -@@ -1359,6 +1367,7 @@ gpt_partition_new (const PedDisk *disk, - gpt_part_data->legacy_boot = 0; - gpt_part_data->prep = 0; - gpt_part_data->translated_name = 0; -+ gpt_part_data->irst = 0; - uuid_generate ((unsigned char *) &gpt_part_data->uuid); - swap_uuid_and_efi_guid ((unsigned char *) (&gpt_part_data->uuid)); - memset (gpt_part_data->name, 0, sizeof gpt_part_data->name); -@@ -1477,6 +1486,11 @@ gpt_partition_set_system (PedPartition *part, - gpt_part_data->type = PARTITION_APPLE_TV_RECOVERY_GUID; - return 1; - } -+ if (gpt_part_data->irst) -+ { -+ gpt_part_data->type = PARTITION_IRST_GUID; -+ return 1; -+ } - - if (fs_type) - { -@@ -1619,6 +1633,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_BIOS_GRUB: -@@ -1632,6 +1647,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_RAID: -@@ -1645,6 +1661,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_LVM: -@@ -1658,6 +1675,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_HPSERVICE: -@@ -1671,6 +1689,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_MSFT_RESERVED: -@@ -1684,6 +1703,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftdata - = gpt_part_data->msftrecv - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_MSFT_DATA: -@@ -1697,6 +1717,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftres - = gpt_part_data->msftrecv - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - gpt_part_data->msftdata = 1; - } else { -@@ -1714,6 +1735,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->msftdata - = gpt_part_data->msftres - = gpt_part_data->prep -+ = gpt_part_data->irst - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_APPLE_TV_RECOVERY: -@@ -1738,7 +1760,22 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - = gpt_part_data->bios_grub - = gpt_part_data->hp_service - = gpt_part_data->msftres -+ = gpt_part_data->irst -+ = gpt_part_data->atvrecv -+ = gpt_part_data->msftrecv = 0; -+ return gpt_partition_set_system (part, part->fs_type); -+ case PED_PARTITION_IRST: -+ gpt_part_data->irst = state; -+ if (state) -+ gpt_part_data->boot -+ = gpt_part_data->raid -+ = gpt_part_data->lvm -+ = gpt_part_data->bios_grub -+ = gpt_part_data->hp_service -+ = gpt_part_data->msftres -+ = gpt_part_data->msftdata - = gpt_part_data->msftrecv -+ = gpt_part_data->prep - = gpt_part_data->atvrecv = 0; - return gpt_partition_set_system (part, part->fs_type); - case PED_PARTITION_HIDDEN: -@@ -1789,6 +1826,8 @@ gpt_partition_get_flag (const PedPartition *part, PedPartitionFlag flag) - return gpt_part_data->legacy_boot; - case PED_PARTITION_PREP: - return gpt_part_data->prep; -+ case PED_PARTITION_IRST: -+ return gpt_part_data->irst; - case PED_PARTITION_SWAP: - case PED_PARTITION_LBA: - case PED_PARTITION_ROOT: -@@ -1816,6 +1855,7 @@ gpt_partition_is_flag_available (const PedPartition *part, - case PED_PARTITION_HIDDEN: - case PED_PARTITION_LEGACY_BOOT: - case PED_PARTITION_PREP: -+ case PED_PARTITION_IRST: - return 1; - case PED_PARTITION_SWAP: - case PED_PARTITION_ROOT: --- -1.9.3 - diff --git a/0076-libparted-Add-UEFI-System-Partition-flag.patch b/0076-libparted-Add-UEFI-System-Partition-flag.patch deleted file mode 100644 index f08802e..0000000 --- a/0076-libparted-Add-UEFI-System-Partition-flag.patch +++ /dev/null @@ -1,241 +0,0 @@ -From 6a5b3b5727845af0c5cef35dee3d8e8c69262fdc Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:25:04 -0700 -Subject: [PATCH 076/131] libparted: Add UEFI System Partition flag. - -This adds support for the ESP partition type on MS-DOS. It also aliases -it to the boot flag on GPT which sets the ESP GUID type. - -* NEWS (New Features): Mention it. -* doc/C/parted.8: Document esp flag. -* doc/parted.texti: Document esp flag. -* include/parted/disk.in.h (_PedPartitionFlag): Add PED_PARTITION_ESP flag -* libparted/disk.c (ped_partition_flag_get_name): Add esp flag -* libparted/labels/dos.c (DosPartitionData): Likewise -(raw_part_parse): Likewise -(msdos_partition_new): Likewise -(msdos_partition_duplicate): Likewise -(msdos_partition_set_system): Likewise -(clear_flags): Likewise -(msdos_partition_set_flag): Likewise -(msdos_partition_get_flag): Likewise -(msdos_partition_is_flag_available): Likewise -* libparted/labels/gpt.c (gpt_partition_set_flag): Add PED_PARTITION_ESP -(gpt_partition_get_flag): Likewise -(gpt_partition_is_flag_available): Likewise ---- - NEWS | 3 +++ - doc/C/parted.8 | 2 +- - doc/parted.texi | 4 ++++ - include/parted/disk.in.h | 5 +++-- - libparted/disk.c | 2 ++ - libparted/labels/dos.c | 21 +++++++++++++++++++++ - libparted/labels/gpt.c | 3 +++ - 7 files changed, 37 insertions(+), 3 deletions(-) - -diff --git a/NEWS b/NEWS -index 27710b6..abb73c6 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,9 @@ GNU parted NEWS -*- outline -*- - - ** New Features - -+ Added new partition type flag, esp, to set the type to 0xEF on MS-DOS. -+ Also aliased to boot on GPT to set the UEFI ESP GUID. -+ - Added new partition type flag, irst, for use with Intel Rapid Start - Technology. On MS-DOS disk labels it sets the type to 0x84 and on GPT - it sets the GUID to D3BFE2DE-3DAF-11DF-BA-40-E3A556D89593. -diff --git a/doc/C/parted.8 b/doc/C/parted.8 -index 2f8e9f5..f8e6a3d 100644 ---- a/doc/C/parted.8 -+++ b/doc/C/parted.8 -@@ -104,7 +104,7 @@ or an LVM logical volume if necessary. - .B set \fIpartition\fP \fIflag\fP \fIstate\fP - Change the state of the \fIflag\fP on \fIpartition\fP to \fIstate\fP. - Supported flags are: "boot", "root", "swap", "hidden", "raid", "lvm", "lba", --"legacy_boot", "irst" and "palo". -+"legacy_boot", "irst", "esp" and "palo". - \fIstate\fP should be either "on" or "off". - .TP - .B unit \fIunit\fP -diff --git a/doc/parted.texi b/doc/parted.texi -index 4c63fe3..9e00808 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -840,6 +840,10 @@ filesystems). - (MS-DOS, GPT) - this flag identifies an Intel Rapid Start Technology - partition. - -+@item esp -+(MS-DOS, GPT) - this flag identifies a UEFI System Partition. On GPT -+it is an alias for boot. -+ - @item lba - (MS-DOS) - this flag can be enabled to tell MS DOS, MS Windows 9x and - MS Windows ME based operating systems to use Linear (LBA) mode. -diff --git a/include/parted/disk.in.h b/include/parted/disk.in.h -index 585383d..d144e21 100644 ---- a/include/parted/disk.in.h -+++ b/include/parted/disk.in.h -@@ -74,10 +74,11 @@ enum _PedPartitionFlag { - PED_PARTITION_DIAG=14, - PED_PARTITION_LEGACY_BOOT=15, - PED_PARTITION_MSFT_DATA=16, -- PED_PARTITION_IRST=17 -+ PED_PARTITION_IRST=17, -+ PED_PARTITION_ESP=18 - }; - #define PED_PARTITION_FIRST_FLAG PED_PARTITION_BOOT --#define PED_PARTITION_LAST_FLAG PED_PARTITION_IRST -+#define PED_PARTITION_LAST_FLAG PED_PARTITION_ESP - - enum _PedDiskTypeFeature { - PED_DISK_TYPE_EXTENDED=1, /**< supports extended partitions */ -diff --git a/libparted/disk.c b/libparted/disk.c -index 18c94ac..5421c03 100644 ---- a/libparted/disk.c -+++ b/libparted/disk.c -@@ -2404,6 +2404,8 @@ ped_partition_flag_get_name (PedPartitionFlag flag) - return N_("legacy_boot"); - case PED_PARTITION_IRST: - return N_("irst"); -+ case PED_PARTITION_ESP: -+ return N_("esp"); - - default: - ped_exception_throw ( -diff --git a/libparted/labels/dos.c b/libparted/labels/dos.c -index c754970..eff1c03 100644 ---- a/libparted/labels/dos.c -+++ b/libparted/labels/dos.c -@@ -92,6 +92,7 @@ static const char MBR_BOOT_CODE[] = { - #define PARTITION_SUN_UFS 0xbf - #define PARTITION_DELL_DIAG 0xde - #define PARTITION_GPT 0xee -+#define PARTITION_ESP 0xef - #define PARTITION_PALO 0xf0 - #define PARTITION_PREP 0x41 - #define PARTITION_LINUX_RAID 0xfd -@@ -161,6 +162,7 @@ typedef struct { - int prep; - int diag; - int irst; -+ int esp; - OrigState* orig; /* used for CHS stuff */ - } DosPartitionData; - -@@ -927,6 +929,7 @@ raw_part_parse (const PedDisk* disk, const DosRawPartition* raw_part, - dos_data->palo = raw_part->type == PARTITION_PALO; - dos_data->prep = raw_part->type == PARTITION_PREP; - dos_data->irst = raw_part->type == PARTITION_IRST; -+ dos_data->esp = raw_part->type == PARTITION_ESP; - dos_data->orig = ped_malloc (sizeof (OrigState)); - if (!dos_data->orig) { - ped_partition_destroy (part); -@@ -1320,6 +1323,7 @@ msdos_partition_new (const PedDisk* disk, PedPartitionType part_type, - dos_data->palo = 0; - dos_data->prep = 0; - dos_data->irst = 0; -+ dos_data->esp = 0; - } else { - part->disk_specific = NULL; - } -@@ -1356,6 +1360,7 @@ msdos_partition_duplicate (const PedPartition* part) - new_dos_data->palo = old_dos_data->palo; - new_dos_data->prep = old_dos_data->prep; - new_dos_data->irst = old_dos_data->irst; -+ new_dos_data->esp = old_dos_data->esp; - - if (old_dos_data->orig) { - new_dos_data->orig = ped_malloc (sizeof (OrigState)); -@@ -1405,6 +1410,7 @@ msdos_partition_set_system (PedPartition* part, - dos_data->palo = 0; - dos_data->prep = 0; - dos_data->irst = 0; -+ dos_data->esp = 0; - if (dos_data->lba) - dos_data->system = PARTITION_EXT_LBA; - else -@@ -1441,6 +1447,10 @@ msdos_partition_set_system (PedPartition* part, - dos_data->system = PARTITION_IRST; - return 1; - } -+ if (dos_data->esp) { -+ dos_data->system = PARTITION_ESP; -+ return 1; -+ } - - if (!fs_type) - dos_data->system = PARTITION_LINUX; -@@ -1478,6 +1488,7 @@ clear_flags (DosPartitionData *dos_data) - dos_data->palo = 0; - dos_data->prep = 0; - dos_data->irst = 0; -+ dos_data->esp = 0; - dos_data->raid = 0; - } - -@@ -1562,6 +1573,12 @@ msdos_partition_set_flag (PedPartition* part, - dos_data->irst = state; - return ped_partition_set_system (part, part->fs_type); - -+ case PED_PARTITION_ESP: -+ if (state) -+ clear_flags (dos_data); -+ dos_data->esp = state; -+ return ped_partition_set_system (part, part->fs_type); -+ - default: - return 0; - } -@@ -1607,6 +1624,9 @@ msdos_partition_get_flag (const PedPartition* part, PedPartitionFlag flag) - case PED_PARTITION_IRST: - return dos_data->irst; - -+ case PED_PARTITION_ESP: -+ return dos_data->esp; -+ - default: - return 0; - } -@@ -1630,6 +1650,7 @@ msdos_partition_is_flag_available (const PedPartition* part, - case PED_PARTITION_PALO: - case PED_PARTITION_PREP: - case PED_PARTITION_IRST: -+ case PED_PARTITION_ESP: - case PED_PARTITION_DIAG: - return 1; - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index ff87708..42b0360 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -1622,6 +1622,7 @@ gpt_partition_set_flag (PedPartition *part, PedPartitionFlag flag, int state) - - switch (flag) - { -+ case PED_PARTITION_ESP: - case PED_PARTITION_BOOT: - gpt_part_data->boot = state; - if (state) -@@ -1806,6 +1807,7 @@ gpt_partition_get_flag (const PedPartition *part, PedPartitionFlag flag) - return gpt_part_data->raid; - case PED_PARTITION_LVM: - return gpt_part_data->lvm; -+ case PED_PARTITION_ESP: - case PED_PARTITION_BOOT: - return gpt_part_data->boot; - case PED_PARTITION_BIOS_GRUB: -@@ -1856,6 +1858,7 @@ gpt_partition_is_flag_available (const PedPartition *part, - case PED_PARTITION_LEGACY_BOOT: - case PED_PARTITION_PREP: - case PED_PARTITION_IRST: -+ case PED_PARTITION_ESP: - return 1; - case PED_PARTITION_SWAP: - case PED_PARTITION_ROOT: --- -1.9.3 - diff --git a/0077-libparted-Recognize-btrfs-filesystem.patch b/0077-libparted-Recognize-btrfs-filesystem.patch deleted file mode 100644 index 3bdc3a3..0000000 --- a/0077-libparted-Recognize-btrfs-filesystem.patch +++ /dev/null @@ -1,184 +0,0 @@ -From 33273acc7822b382b5e8226ba65453b6229f5dd6 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:25:06 -0700 -Subject: [PATCH 077/131] libparted: Recognize btrfs filesystem - -Add support for showing 'btrfs' in the 'file system' column. Also -allows the used to enter btrfs as the fs type. It doesn't really do -anything -- just sets the partition type to linux. - -* NEWS (Changes in behavior): Mention it. -* doc/parted.texti: Document btrfs fs. -* (libparted/fs/Makefile.am): Add btrfs.c -* (libparted/fs/btrfs/btrfs.c): Probe for btrfs -* (libparted/libparted.c): Register btrfs ---- - NEWS | 3 ++ - doc/parted.texi | 1 + - libparted/fs/Makefile.am | 1 + - libparted/fs/btrfs/btrfs.c | 78 ++++++++++++++++++++++++++++++++++++++++++++++ - libparted/libparted.c | 4 +++ - 5 files changed, 87 insertions(+) - create mode 100644 libparted/fs/btrfs/btrfs.c - -diff --git a/NEWS b/NEWS -index abb73c6..7b69d3d 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,9 @@ GNU parted NEWS -*- outline -*- - - ** New Features - -+ Added support for recognizing btrfs filesystem. This simply displays -+ btrfs in the 'file system' column of the parted output. -+ - Added new partition type flag, esp, to set the type to 0xEF on MS-DOS. - Also aliased to boot on GPT to set the UEFI ESP GUID. - -diff --git a/doc/parted.texi b/doc/parted.texi -index 9e00808..97ce203 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -575,6 +575,7 @@ partition table. - @item NTFS - @item reiserfs - @item ufs -+@item btrfs - @end itemize - - For example, the following creates a logical partition that will contain -diff --git a/libparted/fs/Makefile.am b/libparted/fs/Makefile.am -index aac03cc..1949617 100644 ---- a/libparted/fs/Makefile.am -+++ b/libparted/fs/Makefile.am -@@ -23,6 +23,7 @@ libfs_la_SOURCES = \ - amiga/asfs.c \ - amiga/asfs.h \ - amiga/a-interface.c \ -+ btrfs/btrfs.c \ - ext2/ext2.h \ - ext2/ext2_fs.h \ - ext2/interface.c \ -diff --git a/libparted/fs/btrfs/btrfs.c b/libparted/fs/btrfs/btrfs.c -new file mode 100644 -index 0000000..e5abed6 ---- /dev/null -+++ b/libparted/fs/btrfs/btrfs.c -@@ -0,0 +1,78 @@ -+/* -+ libparted - a library for manipulating disk partitions -+ Copyright (C) 2013 Free Software Foundation, Inc. -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License as published by -+ the Free Software Foundation; either version 3 of the License, or -+ (at your option) any later version. -+ -+ 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. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program. If not, see . -+*/ -+ -+#include -+ -+#include -+#include -+ -+/* Located 64k inside the partition (start of the first btrfs superblock) */ -+#define BTRFS_MAGIC 0x4D5F53665248425FULL /* ascii _BHRfS_M, no null */ -+#define BTRFS_CSUM_SIZE 32 -+#define BTRFS_FSID_SIZE 16 -+ -+ -+static PedGeometry* -+btrfs_probe (PedGeometry* geom) -+{ -+ union { -+ struct { -+ /* Just enough of the btrfs_super_block to get the magic */ -+ uint8_t csum[BTRFS_CSUM_SIZE]; -+ uint8_t fsid[BTRFS_FSID_SIZE]; -+ uint64_t bytenr; -+ uint64_t flags; -+ uint64_t magic; -+ } sb; -+ int8_t sector[8192]; -+ } buf; -+ PedSector offset = (64*1024)/geom->dev->sector_size; -+ -+ if (geom->length < offset+1) -+ return 0; -+ if (!ped_geometry_read (geom, &buf, offset, 1)) -+ return 0; -+ -+ if (PED_LE64_TO_CPU(buf.sb.magic) == BTRFS_MAGIC) { -+ return ped_geometry_new (geom->dev, geom->start, geom->length); -+ } -+ return NULL; -+} -+ -+static PedFileSystemOps btrfs_ops = { -+ probe: btrfs_probe, -+}; -+ -+static PedFileSystemType btrfs_type = { -+ next: NULL, -+ ops: &btrfs_ops, -+ name: "btrfs", -+ block_sizes: ((int[2]){512, 0}) -+}; -+ -+void -+ped_file_system_btrfs_init () -+{ -+ ped_file_system_type_register (&btrfs_type); -+} -+ -+void -+ped_file_system_btrfs_done () -+{ -+ ped_file_system_type_unregister (&btrfs_type); -+} -diff --git a/libparted/libparted.c b/libparted/libparted.c -index 9923bfa..3afbf8e 100644 ---- a/libparted/libparted.c -+++ b/libparted/libparted.c -@@ -109,6 +109,7 @@ extern void ped_file_system_hfs_init (void); - extern void ped_file_system_fat_init (void); - extern void ped_file_system_ext2_init (void); - extern void ped_file_system_nilfs2_init (void); -+extern void ped_file_system_btrfs_init (void); - - static void - init_file_system_types () -@@ -124,6 +125,7 @@ init_file_system_types () - ped_file_system_fat_init (); - ped_file_system_ext2_init (); - ped_file_system_nilfs2_init (); -+ ped_file_system_btrfs_init (); - } - - extern void ped_disk_aix_done (); -@@ -186,6 +188,7 @@ extern void ped_file_system_reiserfs_done (void); - extern void ped_file_system_ufs_done (void); - extern void ped_file_system_xfs_done (void); - extern void ped_file_system_amiga_done (void); -+extern void ped_file_system_btrfs_done (void); - - static void - done_file_system_types () -@@ -201,6 +204,7 @@ done_file_system_types () - ped_file_system_ufs_done (); - ped_file_system_xfs_done (); - ped_file_system_amiga_done (); -+ ped_file_system_btrfs_done (); - } - - static void _done() __attribute__ ((destructor)); --- -1.9.3 - diff --git a/0078-tests-Add-btrfs-and-xfs-to-the-fs-probe-test.patch b/0078-tests-Add-btrfs-and-xfs-to-the-fs-probe-test.patch deleted file mode 100644 index 0b22eee..0000000 --- a/0078-tests-Add-btrfs-and-xfs-to-the-fs-probe-test.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 9279fc06572959c4698deb2f1d3df8daaed66e87 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:25:07 -0700 -Subject: [PATCH 078/131] tests: Add btrfs and xfs to the fs probe test - -* tests/tests/t1700-probe-fs.sh: Add btrfs and xfs ---- - tests/t1700-probe-fs.sh | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index 7ce53d0..0418e73 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -22,7 +22,7 @@ require_512_byte_sector_size_ - dev=loop-file - ss=$sector_size_ - --for type in ext2 ext3 ext4 nilfs2; do -+for type in ext2 ext3 ext4 btrfs xfs nilfs2; do - - ( mkfs.$type -V ) >/dev/null 2>&1 \ - || { warn_ "$ME: no $type support"; continue; } --- -1.9.3 - diff --git a/0079-tests-Restrict-gpt-header-munge-to-little-endian-sys.patch b/0079-tests-Restrict-gpt-header-munge-to-little-endian-sys.patch deleted file mode 100644 index 18b7960..0000000 --- a/0079-tests-Restrict-gpt-header-munge-to-little-endian-sys.patch +++ /dev/null @@ -1,52 +0,0 @@ -From fec001a2c83750c35f47e6e621f3acb22e459c7a Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Sep 2013 12:25:09 -0700 -Subject: [PATCH 079/131] tests: Restrict gpt-header-munge to little-endian - systems - -gpt-header-munge uses perl to manipulate the gpt header for the test. It -only works on 64 bit little-endian systems so restrict it to x86_64 -only. - -* tests/t0210-gpt-resized-partition-entry-array.sh: Skip if not x86_64 -* tests/t0211-gpt-rewrite-header.sh: Skip if not x86_64 ---- - tests/t0210-gpt-resized-partition-entry-array.sh | 5 +++++ - tests/t0211-gpt-rewrite-header.sh | 5 +++++ - 2 files changed, 10 insertions(+) - -diff --git a/tests/t0210-gpt-resized-partition-entry-array.sh b/tests/t0210-gpt-resized-partition-entry-array.sh -index 8854018..512f342 100755 ---- a/tests/t0210-gpt-resized-partition-entry-array.sh -+++ b/tests/t0210-gpt-resized-partition-entry-array.sh -@@ -19,6 +19,11 @@ - . "${srcdir=.}/init.sh"; path_prepend_ ../parted $srcdir - require_perl_digest_crc_ - -+# gpt-header-munge will fail on big-endian systems -+if test $(uname -m) != x86_64; then -+ skip_ 'this test only works on little-endian systems' -+fi -+ - ss=$sector_size_ - - N=2M -diff --git a/tests/t0211-gpt-rewrite-header.sh b/tests/t0211-gpt-rewrite-header.sh -index 58625a2..a87e753 100644 ---- a/tests/t0211-gpt-rewrite-header.sh -+++ b/tests/t0211-gpt-rewrite-header.sh -@@ -23,6 +23,11 @@ - . "${srcdir=.}/init.sh"; path_prepend_ ../parted $srcdir - require_perl_digest_crc_ - -+# gpt-header-munge will fail on big-endian systems -+if test $(uname -m) != x86_64; then -+ skip_ 'this test only works on little-endian systems' -+fi -+ - ss=$sector_size_ - - ns=100 # Initial number of sectors. --- -1.9.3 - diff --git a/0080-libparted-don-t-require-a-system-id-string.patch b/0080-libparted-don-t-require-a-system-id-string.patch deleted file mode 100644 index 14bfdc8..0000000 --- a/0080-libparted-don-t-require-a-system-id-string.patch +++ /dev/null @@ -1,68 +0,0 @@ -From 80f4f42c805ee37392c5cc43d8ac08772b7b1cf1 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 1 Mar 2014 21:23:39 -0500 -Subject: [PATCH 080/131] libparted: don't require a system id string - -Historically the system ID field of a fat boot sector contains a -string identifying the OS that formatted it. It appears that some -recent versions of Windows have stopped bothering with this. Stop -requiring this string to recognize fat as valid. ---- - NEWS | 3 +++ - libparted/fs/fat/bootsector.c | 7 ------- - libparted/fs/r/fat/bootsector.c | 7 ------- - 3 files changed, 3 insertions(+), 14 deletions(-) - -diff --git a/NEWS b/NEWS -index 7b69d3d..88dd1fe 100644 ---- a/NEWS -+++ b/NEWS -@@ -23,6 +23,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ Do not reject a FAT boot sector as invalid because it has no -+ system ID string. -+ - libparted: /dev/md/ symlink can change after libparted dereferences it, - instead it should just use the symlink as given by the caller in the - same way we do with /dev/mapper/. -diff --git a/libparted/fs/fat/bootsector.c b/libparted/fs/fat/bootsector.c -index d4f8dc4..dacc79c 100644 ---- a/libparted/fs/fat/bootsector.c -+++ b/libparted/fs/fat/bootsector.c -@@ -51,13 +51,6 @@ fat_boot_sector_read (FatBootSector* bs, const PedGeometry *geom) - return 0; - } - -- if (!bs->system_id[0]) { -- ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, -- _("File system has an invalid signature for a FAT " -- "file system.")); -- return 0; -- } -- - if (!bs->sector_size - || PED_LE16_TO_CPU (bs->sector_size) % PED_SECTOR_SIZE_DEFAULT) { - ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, -diff --git a/libparted/fs/r/fat/bootsector.c b/libparted/fs/r/fat/bootsector.c -index 07b39cf..3aff1d7 100644 ---- a/libparted/fs/r/fat/bootsector.c -+++ b/libparted/fs/r/fat/bootsector.c -@@ -51,13 +51,6 @@ fat_boot_sector_read (FatBootSector* bs, const PedGeometry *geom) - return 0; - } - -- if (!bs->system_id[0]) { -- ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, -- _("File system has an invalid signature for a FAT " -- "file system.")); -- return 0; -- } -- - if (!bs->sector_size - || PED_LE16_TO_CPU (bs->sector_size) % PED_SECTOR_SIZE_DEFAULT) { - ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, --- -1.9.3 - diff --git a/0081-libparted-sync-partitions-16.patch b/0081-libparted-sync-partitions-16.patch deleted file mode 100644 index 33dee2e..0000000 --- a/0081-libparted-sync-partitions-16.patch +++ /dev/null @@ -1,58 +0,0 @@ -From 026736e9fed89ef00e6e6e84c7e422639ac2715c Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Mon, 23 Dec 2013 15:28:22 -0500 -Subject: [PATCH 081/131] libparted: sync partitions > 16 - -The linux partition sync code was hard coded to only flush -the first 16 partitions. ---- - NEWS | 2 ++ - libparted/arch/linux.c | 5 ++++- - 2 files changed, 6 insertions(+), 1 deletion(-) - -diff --git a/NEWS b/NEWS -index 88dd1fe..9ef8bf4 100644 ---- a/NEWS -+++ b/NEWS -@@ -23,6 +23,8 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ Fix linux partition sync code to flush partitions > 16 -+ - Do not reject a FAT boot sector as invalid because it has no - system ID string. - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 4376d17..71f5034 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -289,6 +289,8 @@ struct blkdev_ioctl_param { - - static char* _device_get_part_path (PedDevice const *dev, int num); - static int _partition_is_mounted_by_path (const char* path); -+static unsigned int _device_get_partition_range(PedDevice const* dev); -+ - - static int - _read_fd (int fd, char **buf) -@@ -1581,6 +1583,7 @@ _flush_cache (PedDevice* dev) - { - LinuxSpecific* arch_specific = LINUX_SPECIFIC (dev); - int i; -+ int lpn = _device_get_partition_range(dev); - - if (dev->read_only) - return; -@@ -1588,7 +1591,7 @@ _flush_cache (PedDevice* dev) - - ioctl (arch_specific->fd, BLKFLSBUF); - -- for (i = 1; i < 16; i++) { -+ for (i = 1; i < lpn; i++) { - char* name; - int fd; - --- -1.9.3 - diff --git a/0082-ui-switch-to-new-style-readline-typedef.patch b/0082-ui-switch-to-new-style-readline-typedef.patch deleted file mode 100644 index 5c4fe32..0000000 --- a/0082-ui-switch-to-new-style-readline-typedef.patch +++ /dev/null @@ -1,32 +0,0 @@ -From cc382c3753e1b430c00df46f0937b74db36ccb8a Mon Sep 17 00:00:00 2001 -From: Gustavo Zacarias -Date: Mon, 3 Mar 2014 10:40:08 -0300 -Subject: [PATCH 082/131] ui: switch to new-style readline typedef - -The CPPFunction typedef (among others) have been deprecated in favour of -specific prototyped typedefs since readline 4.2 (circa 2001). -It's been working since because compatibility typedefs have been in -place until they where removed in the recent readline 6.3 release. -Switch to the new style to avoid build breakage. - -Signed-off-by: Gustavo Zacarias ---- - parted/ui.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/parted/ui.c b/parted/ui.c -index 786deed..b33f6fc 100644 ---- a/parted/ui.c -+++ b/parted/ui.c -@@ -1470,7 +1470,7 @@ init_readline (void) - #ifdef HAVE_LIBREADLINE - if (!opt_script_mode) { - rl_initialize (); -- rl_attempted_completion_function = (CPPFunction*) complete_function; -+ rl_attempted_completion_function = (rl_completion_func_t *) complete_function; - readline_state.in_readline = 0; - } - #endif --- -1.9.3 - diff --git a/0083-libparted-Fix-check-for-backup-header-location.patch b/0083-libparted-Fix-check-for-backup-header-location.patch deleted file mode 100644 index 5214fea..0000000 --- a/0083-libparted-Fix-check-for-backup-header-location.patch +++ /dev/null @@ -1,87 +0,0 @@ -From 8993950f50275724b2cb1c4960977dc78eec2ed2 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 8 Apr 2014 10:54:27 -0700 -Subject: [PATCH 083/131] libparted: Fix check for backup header location - -Add a couple of helper functions for calculating the partition table -entry size (in sectors) and for guessing the end of the disk based on -the LastUsableLBA and the Partition Table Entry size. - -The backup header should be either at the end of the disk, or at what -the primary header thinks is the end of the disk. Prompt to fix the -backup header if it is located any other place. - -* libparted/labels/gpt.c (_ptes_sectors): New function - (_hdr_disk_end): New function - (gpt_read): Use new function to test for pri's idea of end of disk ---- - libparted/labels/gpt.c | 38 +++++++++++++++++++++++++++++++------- - 1 file changed, 31 insertions(+), 7 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 42b0360..c5dea2f 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -693,6 +693,29 @@ _header_is_valid (PedDisk const *disk, GuidPartitionTableHeader_t *gpt, - return crc == PED_LE32_TO_CPU (origcrc); - } - -+/* Return the number of sectors that should be used by the -+ * partition entry table. -+ */ -+static PedSector -+_ptes_sectors(PedDisk const *disk, GuidPartitionTableHeader_t const *gpt) -+{ -+ size_t ptes_bytes = PED_LE32_TO_CPU (gpt->SizeOfPartitionEntry) * -+ PED_LE32_TO_CPU (gpt->NumberOfPartitionEntries); -+ /* Minimum amount of space reserved is 128 128 byte entries */ -+ if (ptes_bytes < 128*128) -+ ptes_bytes = 128*128; -+ return ped_div_round_up (ptes_bytes, disk->dev->sector_size); -+} -+ -+/* Return the header's idea of the last sector of the disk -+ * based on LastUsableLBA and the Partition Entry table. -+ */ -+static PedSector -+_hdr_disk_end(PedDisk const *disk, GuidPartitionTableHeader_t const *gpt) -+{ -+ return PED_LE64_TO_CPU (gpt->LastUsableLBA) + 1 + _ptes_sectors(disk, gpt); -+} -+ - static int - _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - int *update_needed) -@@ -985,13 +1008,14 @@ gpt_read (PedDisk *disk) - { - /* Both are valid. */ - #ifndef DISCOVER_ONLY -- PedSector gpt_disk_end = PED_LE64_TO_CPU (primary_gpt->LastUsableLBA) + 1; -- gpt_disk_end += ((PedSector) (PED_LE32_TO_CPU (primary_gpt->NumberOfPartitionEntries)) * -- (PedSector) (PED_LE32_TO_CPU (primary_gpt->SizeOfPartitionEntry)) / -- disk->dev->sector_size); -- -+ /* The backup header must be at the end of the disk, or at what the primary -+ * header thinks is the end of the disk. -+ */ - gpt_disk_data->AlternateLBA = PED_LE64_TO_CPU (primary_gpt->AlternateLBA); -- if (PED_LE64_TO_CPU (primary_gpt->AlternateLBA) != gpt_disk_end) -+ PedSector pri_disk_end = _hdr_disk_end(disk, primary_gpt); -+ -+ if (gpt_disk_data->AlternateLBA != disk->dev->length -1 && -+ gpt_disk_data->AlternateLBA != pri_disk_end) - { - if (ped_exception_throw - (PED_EXCEPTION_ERROR, -@@ -1002,7 +1026,7 @@ gpt_read (PedDisk *disk) - { - ptt_clear_sectors (disk->dev, - PED_LE64_TO_CPU (primary_gpt->AlternateLBA), 1); -- gpt_disk_data->AlternateLBA = gpt_disk_end; -+ gpt_disk_data->AlternateLBA = disk->dev->length -1; - write_back = 1; - } - } --- -1.9.3 - diff --git a/0084-libparted-Use-common-function-to-calculate-PTE-secto.patch b/0084-libparted-Use-common-function-to-calculate-PTE-secto.patch deleted file mode 100644 index 1fa1def..0000000 --- a/0084-libparted-Use-common-function-to-calculate-PTE-secto.patch +++ /dev/null @@ -1,48 +0,0 @@ -From 3398e82af3d26cc1ab938f2e0896204f11bce4ca Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 8 Apr 2014 11:12:17 -0700 -Subject: [PATCH 084/131] libparted: Use common function to calculate PTE - sectors - -Use _ptes_sectors in _parse_header's calculation to determine if the -disk has been grown. - -* libparted/labels/gpt.c (_parse_header): use _ptes_sectors ---- - libparted/labels/gpt.c | 13 +------------ - 1 file changed, 1 insertion(+), 12 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index c5dea2f..6eff38a 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -751,17 +751,7 @@ _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - space or continue with the current usable area. Only ask once per - parted invocation. */ - -- last_usable_if_grown -- = (disk->dev->length - 2 - -- ((PedSector) (PED_LE32_TO_CPU (gpt->NumberOfPartitionEntries)) * -- (PedSector) (PED_LE32_TO_CPU (gpt->SizeOfPartitionEntry)) / -- disk->dev->sector_size)); -- -- last_usable_min_default = disk->dev->length - 2 - -- GPT_DEFAULT_PARTITION_ENTRY_ARRAY_SIZE / disk->dev->sector_size; -- -- if (last_usable_if_grown > last_usable_min_default) -- last_usable_if_grown = last_usable_min_default; -+ last_usable_if_grown = disk->dev->length - 2 - _ptes_sectors(disk, gpt); - - if (last_usable <= first_usable - || disk->dev->length < last_usable) -@@ -791,7 +781,6 @@ _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - ptt_clear_sectors (disk->dev, - gpt_disk_data->AlternateLBA, 1); - gpt_disk_data->AlternateLBA = disk->dev->length - 1; -- last_usable = last_usable_if_grown; - *update_needed = 1; - } - else if (q != PED_EXCEPTION_UNHANDLED) --- -1.9.3 - diff --git a/0085-tests-Add-emit_superuser_warning-for-gpt-tests.patch b/0085-tests-Add-emit_superuser_warning-for-gpt-tests.patch deleted file mode 100644 index ac014d9..0000000 --- a/0085-tests-Add-emit_superuser_warning-for-gpt-tests.patch +++ /dev/null @@ -1,73 +0,0 @@ -From 368e47b1c00ed36c07275815f69274a985b4aab8 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 25 Mar 2014 17:44:08 -0700 -Subject: [PATCH 085/131] tests: Add emit_superuser_warning for gpt tests - -When parted runs without script mode it will print a warning about not -being superuser. Add the library call to add this to expected output -from the tests. - -* tests/t0281-gpt-grow.sh: Add emit_superuser_warning -* tests/t0282-gpt-move-backup.sh: Add emit_superuser_warning -* tests/t0283-overlap-partitions.sh: Add emit_superuser_warning ---- - tests/t0281-gpt-grow.sh | 3 ++- - tests/t0282-gpt-move-backup.sh | 3 ++- - tests/t0283-overlap-partitions.sh | 6 ++++-- - 3 files changed, 8 insertions(+), 4 deletions(-) - -diff --git a/tests/t0281-gpt-grow.sh b/tests/t0281-gpt-grow.sh -index e373578..0cef138 100644 ---- a/tests/t0281-gpt-grow.sh -+++ b/tests/t0281-gpt-grow.sh -@@ -75,7 +75,8 @@ mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ - -e "s,^.*/lt-parted: ,parted: ," o2 > out - - # check for expected diagnostic --cat < exp || fail=1 -+emit_superuser_warning > exp || fail=1 -+cat <> exp || fail=1 - Warning: Not all of the space available to DEVICE appears to be used, you can fix the GPT to use all of the space (an extra 500 blocks) or continue with the current setting? - Fix/Ignore? f - Model: (file) -diff --git a/tests/t0282-gpt-move-backup.sh b/tests/t0282-gpt-move-backup.sh -index 9750ed7..1a296ad 100644 ---- a/tests/t0282-gpt-move-backup.sh -+++ b/tests/t0282-gpt-move-backup.sh -@@ -75,7 +75,8 @@ mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ - -e "s,^.*/lt-parted: ,parted: ," o2 > out - - # check for expected diagnostic --cat < exp || fail=1 -+emit_superuser_warning > exp || fail=1 -+cat <> exp || fail=1 - Error: The backup GPT table is not at the end of the disk, as it should be. Fix, by moving the backup to the end (and removing the old backup)? - Fix/Ignore? f - Model: (file) -diff --git a/tests/t0283-overlap-partitions.sh b/tests/t0283-overlap-partitions.sh -index 2a53407..c7ae52a 100644 ---- a/tests/t0283-overlap-partitions.sh -+++ b/tests/t0283-overlap-partitions.sh -@@ -74,7 +74,8 @@ mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ - -e "s,^.*/lt-parted: ,parted: ," -e "s/^GNU Parted .*$/GNU Parted VERSION/" o2 > out - - # check for expected output --cat < exp || fail=1 -+emit_superuser_warning > exp || fail=1 -+cat <> exp || fail=1 - GNU Parted VERSION - Using DEVICE - Welcome to GNU Parted! Type 'help' to view a list of commands. -@@ -116,7 +117,8 @@ mv out o2 && sed -e "s,/.*/$dev,DEVICE,;s, * ,,g;s, $,," \ - -e "s,^.*/lt-parted: ,parted: ," -e "s/^GNU Parted .*$/GNU Parted VERSION/" o2 > out - - # check for expected output --cat < exp || fail=1 -+emit_superuser_warning > exp || fail=1 -+cat <> exp || fail=1 - GNU Parted VERSION - Using DEVICE - Welcome to GNU Parted! Type 'help' to view a list of commands. --- -1.9.3 - diff --git a/0086-tests-Use-msdos-overlap-to-setup-t0283.patch b/0086-tests-Use-msdos-overlap-to-setup-t0283.patch deleted file mode 100644 index eb5299b..0000000 --- a/0086-tests-Use-msdos-overlap-to-setup-t0283.patch +++ /dev/null @@ -1,102 +0,0 @@ -From 2ee70befff05e6d5004df7491b373445531318e7 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 26 Mar 2014 09:35:07 -0700 -Subject: [PATCH 086/131] tests: Use msdos-overlap to setup t0283 - -xxd isn't present in minimal build systems, as it is part of vim. Change -to using a simple python script to mangle the msdos disklabel for the -test. - -* tests/msdos-overlap.py: New file -* tests/t0283-overlap-partitions.sh: Use msdos-overlap.py ---- - tests/msdos-overlap.py | 25 ++++++++++++++++++++++++ - tests/t0283-overlap-partitions.sh | 40 +++------------------------------------ - 2 files changed, 28 insertions(+), 37 deletions(-) - create mode 100755 tests/msdos-overlap.py - -diff --git a/tests/msdos-overlap.py b/tests/msdos-overlap.py -new file mode 100755 -index 0000000..5bddfb0 ---- /dev/null -+++ b/tests/msdos-overlap.py -@@ -0,0 +1,25 @@ -+#!/usr/bin/python -+""" -+ Write an overlapping partition to a msdos disk -+ -+ Call with disk image/device to mangle -+""" -+import sys -+ -+BAD_ENTRY = (0x72, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -+ 0x01, 0x10, 0x83, 0x03, 0x20, 0x4f, 0x00, 0x08, -+ 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, -+ 0x00, 0x50, 0x83, 0x00, 0x0a, 0x7a, 0xff, 0x27, -+ 0x00, 0x00, 0x0a, 0x15, 0x00, 0x00, 0x00, 0x00 ) -+OFFSET = 0x1b8 -+ -+if len(sys.argv) < 2: -+ print "%s: " -+ sys.exit(1) -+ -+data = "".join(chr(c) for c in BAD_ENTRY) -+with open(sys.argv[1], "rb+") as f: -+ f.seek(OFFSET, 0) -+ f.write(data) -+ -+sys.exit(0) -diff --git a/tests/t0283-overlap-partitions.sh b/tests/t0283-overlap-partitions.sh -index c7ae52a..221332d 100644 ---- a/tests/t0283-overlap-partitions.sh -+++ b/tests/t0283-overlap-partitions.sh -@@ -21,43 +21,9 @@ - require_512_byte_sector_size_ - dev=loop-file - --truncate -s 10m $dev || fail=1 -- --# write damaged label --xxd -r - $dev < out 2>&1 || fail=1 --- -1.9.3 - diff --git a/0087-testing-Use-little-endian-packing-in-gpt-tests.patch b/0087-testing-Use-little-endian-packing-in-gpt-tests.patch deleted file mode 100644 index c9e7ad1..0000000 --- a/0087-testing-Use-little-endian-packing-in-gpt-tests.patch +++ /dev/null @@ -1,152 +0,0 @@ -From dbcd731411369cd40c842ca492988308b444c42c Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 8 Apr 2014 17:08:22 -0700 -Subject: [PATCH 087/131] testing: Use little-endian packing in gpt tests - -Fix gpt-header-move.py and gpt-header-munge to use little endian when -packing and unpacking. This allows us to turn the t0210 and t0211 tests -back on for big-endian systems. - -* tests/gpt-header-move.py: Use little endian for pack/unpack -* tests/gpt-header-munge: Same -* tests/t-lib-helpers.sh: Add requires_64bit_ that checks for x86_64 and ppc64 -* tests/t0210-gpt-resized-partition-entry-array.sh: Remove x86_64 test -* tests/t0211-gpt-rewrite-header.sh: Same ---- - tests/gpt-header-move.py | 16 ++++++++-------- - tests/gpt-header-munge | 6 +++--- - tests/t-lib-helpers.sh | 12 ++++++++++++ - tests/t0210-gpt-resized-partition-entry-array.sh | 6 ++---- - tests/t0211-gpt-rewrite-header.sh | 6 ++---- - 5 files changed, 27 insertions(+), 19 deletions(-) - -diff --git a/tests/gpt-header-move.py b/tests/gpt-header-move.py -index 69d1479..977febb 100644 ---- a/tests/gpt-header-move.py -+++ b/tests/gpt-header-move.py -@@ -8,14 +8,14 @@ import sys - file = open(sys.argv[1],'rb+') - file.seek(512) - gptheader = file.read(512) --altlba = unpack_from('q', gptheader,offset=32)[0] -+altlba = unpack_from(' -Date: Sat, 16 Feb 2013 10:16:20 +0800 -Subject: [PATCH 088/131] libparted: fix several integer overflows with dvh - labels - -Integer overflows was found in libparted/labels/dvh.c, while attemptting -assign unsigned int values to int types in some places. - -Defined by unsigned int instead. - -* libparted/labels/dvh.h: Change int to unsigned int - -Signed-off-by: Ming Liu -Signed-off-by: Brian C. Lane ---- - libparted/labels/dvh.h | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) - -diff --git a/libparted/labels/dvh.h b/libparted/labels/dvh.h -index 4c25c99..7e7fae7 100644 ---- a/libparted/labels/dvh.h -+++ b/libparted/labels/dvh.h -@@ -112,8 +112,8 @@ struct device_parameters { - - struct volume_directory { - char vd_name[VDNAMESIZE]; /* name */ -- int vd_lbn; /* logical block number */ -- int vd_nbytes; /* file length in bytes */ -+ unsigned int vd_lbn; /* logical block number */ -+ unsigned int vd_nbytes; /* file length in bytes */ - }; - - /* -@@ -125,9 +125,9 @@ struct volume_directory { - * NOTE: pt_firstlbn SHOULD BE CYLINDER ALIGNED - */ - struct partition_table { /* one per logical partition */ -- int pt_nblks; /* # of logical blks in partition */ -- int pt_firstlbn; /* first lbn of partition */ -- int pt_type; /* use of partition */ -+ unsigned int pt_nblks; /* # of logical blks in partition */ -+ unsigned int pt_firstlbn; /* first lbn of partition */ -+ int pt_type; /* use of partition */ - }; - - #define PTYPE_VOLHDR 0 /* partition is volume header */ --- -1.9.3 - diff --git a/0089-tests-Use-force-for-xfs-in-t1700-and-a-larger-file.patch b/0089-tests-Use-force-for-xfs-in-t1700-and-a-larger-file.patch deleted file mode 100644 index 71ed035..0000000 --- a/0089-tests-Use-force-for-xfs-in-t1700-and-a-larger-file.patch +++ /dev/null @@ -1,52 +0,0 @@ -From bb181a7ec46f2820368359b7aba0917be089e0c5 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Mon, 14 Apr 2014 15:04:17 -0700 -Subject: [PATCH 089/131] tests: Use force for xfs in t1700 and a larger file - -Also use sparse files that are (with 512B blocks) 128M so that they are -large enough for all the filesystems. - -* tests/t1700-probe-fs.sh: Make changes. ---- - tests/t1700-probe-fs.sh | 10 ++++++---- - 1 file changed, 6 insertions(+), 4 deletions(-) - -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index 0418e73..08ec7d9 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -21,17 +21,19 @@ require_512_byte_sector_size_ - - dev=loop-file - ss=$sector_size_ -+n_sectors=$((257*1024)) - - for type in ext2 ext3 ext4 btrfs xfs nilfs2; do - - ( mkfs.$type -V ) >/dev/null 2>&1 \ - || { warn_ "$ME: no $type support"; continue; } - -- case $type in ext*) n_sectors=8000 force=-F;; -- *) n_sectors=$((257*1024)) force=;; esac -+ case $type in ext*) force=-F;; -+ xfs) force=-f;; -+ *) force=;; esac - - # create an $type file system -- dd if=/dev/zero of=$dev bs=$ss count=$n_sectors >/dev/null || fail=1 -+ dd if=/dev/null of=$dev bs=$ss count=$n_sectors >/dev/null || fail=1 - mkfs.$type $force $dev || { warn_ $ME: mkfs.$type failed; fail=1; continue; } - - # probe the $type file system -@@ -43,7 +45,7 @@ done - # Some features should indicate ext4 by themselves. - for feature in uninit_bg flex_bg; do - # create an ext3 file system -- dd if=/dev/zero of=$dev bs=1024 count=4096 >/dev/null || fail=1 -+ dd if=/dev/null of=$dev bs=1024 count=4096 >/dev/null || fail=1 - mkfs.ext3 -F $dev >/dev/null || skip_ "mkfs.ext3 failed" - - # set the feature --- -1.9.3 - diff --git a/0090-tests-t1700-change-count-to-seek.patch b/0090-tests-t1700-change-count-to-seek.patch deleted file mode 100644 index 5f77e75..0000000 --- a/0090-tests-t1700-change-count-to-seek.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 33fdfa0f29d0d9c0135da6da80e6953d8f509b7b Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Thu, 17 Apr 2014 12:12:29 -0700 -Subject: [PATCH 090/131] tests: t1700 change count to seek - -Fix a typo when changing to sparse images. - -* tests/t1700-probe-fs.sh: count should be seek. ---- - tests/t1700-probe-fs.sh | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index 08ec7d9..bf6ad9c 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -33,7 +33,7 @@ for type in ext2 ext3 ext4 btrfs xfs nilfs2; do - *) force=;; esac - - # create an $type file system -- dd if=/dev/null of=$dev bs=$ss count=$n_sectors >/dev/null || fail=1 -+ dd if=/dev/null of=$dev bs=$ss seek=$n_sectors >/dev/null || fail=1 - mkfs.$type $force $dev || { warn_ $ME: mkfs.$type failed; fail=1; continue; } - - # probe the $type file system -@@ -45,7 +45,7 @@ done - # Some features should indicate ext4 by themselves. - for feature in uninit_bg flex_bg; do - # create an ext3 file system -- dd if=/dev/null of=$dev bs=1024 count=4096 >/dev/null || fail=1 -+ dd if=/dev/null of=$dev bs=1024 seek=4096 >/dev/null || fail=1 - mkfs.ext3 -F $dev >/dev/null || skip_ "mkfs.ext3 failed" - - # set the feature --- -1.9.3 - diff --git a/0091-libparted-remove-last_usable_if_grown.patch b/0091-libparted-remove-last_usable_if_grown.patch deleted file mode 100644 index 74af22f..0000000 --- a/0091-libparted-remove-last_usable_if_grown.patch +++ /dev/null @@ -1,28 +0,0 @@ -From d1ca2a5eacc2de4b9f755c10fcf8b14e6c1d2dc1 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Fri, 18 Apr 2014 11:01:03 -0400 -Subject: [PATCH 091/131] libparted: remove last_usable_if_grown - -Commit 3398e82a: "libparted: Use common function to calculate PTE sectors" -removed usage of the last_usable_if_grown variable, resulting in an error -because it is now unused but still defined. ---- - libparted/labels/gpt.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 6eff38a..5c8df59 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -723,7 +723,7 @@ _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - GPTDiskData *gpt_disk_data = disk->disk_specific; - PedSector first_usable; - PedSector last_usable; -- PedSector last_usable_if_grown, last_usable_min_default; -+ PedSector last_usable_if_grown; - static int asked_already; - - #ifndef DISCOVER_ONLY --- -1.9.3 - diff --git a/0092-tests-fix-t1700.patch b/0092-tests-fix-t1700.patch deleted file mode 100644 index 6dbf35c..0000000 --- a/0092-tests-fix-t1700.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 60d7ceec9cbabbf114bb05b391f355fdbe418571 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Fri, 18 Apr 2014 12:29:57 -0400 -Subject: [PATCH 092/131] tests: fix t1700 - -bb181a7e: "tests: Use force for xfs in t1700 and a larger file" caused -the previous filesystem signatures to be left in the image file -causing mkfs.nilfs2 to complain that there is already an xfs filesystem -there, and hang the test suite waiting for an answer to proceed or not. -Remove the file between filesystems so it is recreated cleanly again. ---- - tests/t1700-probe-fs.sh | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index bf6ad9c..2ba2f95 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -39,6 +39,7 @@ for type in ext2 ext3 ext4 btrfs xfs nilfs2; do - # probe the $type file system - parted -m -s $dev u s print >out 2>&1 || fail=1 - grep '^1:.*:'$type'::;$' out || { cat out; fail=1; } -+ rm $dev - - done - --- -1.9.3 - diff --git a/0093-tests-fix-t2310-dos-extended-2-sector-min-offset.sh.patch b/0093-tests-fix-t2310-dos-extended-2-sector-min-offset.sh.patch deleted file mode 100644 index ce2c524..0000000 --- a/0093-tests-fix-t2310-dos-extended-2-sector-min-offset.sh.patch +++ /dev/null @@ -1,45 +0,0 @@ -From d0a4cc1b57750a92afb48b229e4791154afa322b Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 29 Mar 2014 16:29:06 -0400 -Subject: [PATCH 093/131] tests: fix t2310-dos-extended-2-sector-min-offset.sh - -This test was ignoring the requested sector size and always using -512 bytes per sector. Fix it to use the requested sector size. ---- - tests/t2310-dos-extended-2-sector-min-offset.sh | 9 +++------ - 1 file changed, 3 insertions(+), 6 deletions(-) - -diff --git a/tests/t2310-dos-extended-2-sector-min-offset.sh b/tests/t2310-dos-extended-2-sector-min-offset.sh -index f74cba5..53843ab 100644 ---- a/tests/t2310-dos-extended-2-sector-min-offset.sh -+++ b/tests/t2310-dos-extended-2-sector-min-offset.sh -@@ -23,7 +23,8 @@ require_root_ - require_scsi_debug_module_ - - # create memory-backed device --scsi_debug_setup_ dev_size_mb=1 > dev-name || -+ss=$sector_size_ -+scsi_debug_setup_ sector_size=$ss dev_size_mb=1 > dev-name || - skip_ 'failed to create scsi_debug device' - scsi_dev=$(cat dev-name) - p1=${scsi_dev}1 -@@ -31,15 +32,11 @@ p5=${scsi_dev}5 - - cat < exp || framework_failure - BYT; --$scsi_dev:2048s:scsi:512:512:msdos:Linux scsi_debug:; -+$scsi_dev:$((2048*512/$ss))s:scsi:$ss:$ss:msdos:Linux scsi_debug:; - 1:64s:128s:65s:::lba; - 5:65s:128s:64s:::; - EOF - --cat < err.exp || framework_failure --Error: Partition(s) 5 on $scsi_dev have been written, but we have been unable to inform the kernel of the change, probably because it/they are in use. As a result, the old partition(s) will remain in use. You should reboot now before making further changes. --EOF -- - # Create a DOS label with an extended partition starting at sector 64. - parted -s $scsi_dev mklabel msdos || fail=1 - parted --align=min -s $scsi_dev mkpart extended 64s 128s> out 2>&1 || fail=1 --- -1.9.3 - diff --git a/0094-Fix-filesystem-detection-on-non-512-byte-sectors.patch b/0094-Fix-filesystem-detection-on-non-512-byte-sectors.patch deleted file mode 100644 index 9e1ce5a..0000000 --- a/0094-Fix-filesystem-detection-on-non-512-byte-sectors.patch +++ /dev/null @@ -1,1329 +0,0 @@ -From 80678bdd957cf49a9ccfc8b88ba3fb8b4c63fc12 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Mon, 17 Mar 2014 22:07:55 -0400 -Subject: [PATCH 094/131] Fix filesystem detection on non 512 byte sectors - -Enable probing for filesystems with non 512 byte sectors, and fix up each -filesystem to correctly handle that. Remove unused field from the fs type -structure listing acceptable sector sizes. ---- - NEWS | 2 ++ - include/parted/filesys.in.h | 1 - - libparted/filesys.c | 5 ---- - libparted/fs/amiga/affs.c | 22 ++-------------- - libparted/fs/amiga/apfs.c | 6 ++--- - libparted/fs/amiga/asfs.c | 3 ++- - libparted/fs/btrfs/btrfs.c | 1 - - libparted/fs/ext2/interface.c | 18 ++++--------- - libparted/fs/fat/bootsector.c | 50 +++++------------------------------- - libparted/fs/fat/bootsector.h | 3 +-- - libparted/fs/fat/fat.c | 12 ++++----- - libparted/fs/fat/fat.h | 4 +-- - libparted/fs/hfs/hfs.c | 7 ----- - libparted/fs/hfs/probe.c | 13 ++++++---- - libparted/fs/jfs/jfs.c | 29 ++++++++------------- - libparted/fs/linux_swap/linux_swap.c | 41 ++++++----------------------- - libparted/fs/nilfs2/nilfs2.c | 36 ++++++++++---------------- - libparted/fs/ntfs/ntfs.c | 13 ++++------ - libparted/fs/r/fat/bootsector.c | 32 +++++++++++++---------- - libparted/fs/r/fat/bootsector.h | 8 +++--- - libparted/fs/r/fat/fat.c | 29 +++++++++++---------- - libparted/fs/r/fat/fat.h | 4 +-- - libparted/fs/r/fat/resize.c | 4 +-- - libparted/fs/r/fat/table.c | 4 +-- - libparted/fs/reiserfs/reiserfs.c | 23 +++++++---------- - libparted/fs/ufs/ufs.c | 27 ++++++++++--------- - libparted/fs/xfs/xfs.c | 26 ++++++++----------- - 27 files changed, 148 insertions(+), 275 deletions(-) - -diff --git a/NEWS b/NEWS -index 9ef8bf4..ae65106 100644 ---- a/NEWS -+++ b/NEWS -@@ -23,6 +23,8 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ Fix filesystem detection on non 512 byte sector sizes -+ - Fix linux partition sync code to flush partitions > 16 - - Do not reject a FAT boot sector as invalid because it has no -diff --git a/include/parted/filesys.in.h b/include/parted/filesys.in.h -index d9f626b..b42d7c9 100644 ---- a/include/parted/filesys.in.h -+++ b/include/parted/filesys.in.h -@@ -46,7 +46,6 @@ struct _PedFileSystemOps { - struct _PedFileSystemType { - PedFileSystemType* next; - const char* const name; /**< name of the file system type */ -- const int* block_sizes; - PedFileSystemOps* const ops; - }; - -diff --git a/libparted/filesys.c b/libparted/filesys.c -index 1870808..1bfe32d 100644 ---- a/libparted/filesys.c -+++ b/libparted/filesys.c -@@ -198,11 +198,6 @@ ped_file_system_probe_specific ( - PED_ASSERT (fs_type->ops->probe != NULL); - PED_ASSERT (geom != NULL); - -- /* Fail all fs-specific probe-related tests when sector size -- is not the default. */ -- if (geom->dev->sector_size != PED_SECTOR_SIZE_DEFAULT) -- return 0; -- - if (!ped_device_open (geom->dev)) - return 0; - result = fs_type->ops->probe (geom); -diff --git a/libparted/fs/amiga/affs.c b/libparted/fs/amiga/affs.c -index 6b7624d..a97cc54 100644 ---- a/libparted/fs/amiga/affs.c -+++ b/libparted/fs/amiga/affs.c -@@ -55,7 +55,8 @@ _generic_affs_probe (PedGeometry* geom, uint32_t kind) - - PED_ASSERT (geom != NULL); - PED_ASSERT (geom->dev != NULL); -- -+ if (geom->dev->sector_size != 512) -+ return NULL; - /* Finds the blocksize, prealloc and reserved values of the partition block */ - if (!(part = ped_malloc (PED_SECTOR_SIZE_DEFAULT*blocksize))) { - ped_exception_throw(PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, -@@ -216,97 +217,78 @@ static PedFileSystemOps _amufs5_ops = { - probe: _amufs5_probe, - }; - --#define AFFS_BLOCK_SIZES ((int[5]){512, 1024, 2048, 4096, 0}) --#define AMUFS_BLOCK_SIZES ((int[2]){512, 0}) -- -- - PedFileSystemType _affs0_type = { - next: NULL, - ops: &_affs0_ops, - name: "affs0", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _affs1_type = { - next: NULL, - ops: &_affs1_ops, - name: "affs1", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _affs2_type = { - next: NULL, - ops: &_affs2_ops, - name: "affs2", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _affs3_type = { - next: NULL, - ops: &_affs3_ops, - name: "affs3", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _affs4_type = { - next: NULL, - ops: &_affs4_ops, - name: "affs4", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _affs5_type = { - next: NULL, - ops: &_affs5_ops, - name: "affs5", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _affs6_type = { - next: NULL, - ops: &_affs6_ops, - name: "affs6", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _affs7_type = { - next: NULL, - ops: &_affs7_ops, - name: "affs7", -- block_sizes: AFFS_BLOCK_SIZES - }; - PedFileSystemType _amufs_type = { - next: NULL, - ops: &_amufs_ops, - name: "amufs", -- block_sizes: AMUFS_BLOCK_SIZES - }; - PedFileSystemType _amufs0_type = { - next: NULL, - ops: &_amufs0_ops, - name: "amufs0", -- block_sizes: AMUFS_BLOCK_SIZES - }; - PedFileSystemType _amufs1_type = { - next: NULL, - ops: &_amufs1_ops, - name: "amufs1", -- block_sizes: AMUFS_BLOCK_SIZES - }; - PedFileSystemType _amufs2_type = { - next: NULL, - ops: &_amufs2_ops, - name: "amufs2", -- block_sizes: AMUFS_BLOCK_SIZES - }; - PedFileSystemType _amufs3_type = { - next: NULL, - ops: &_amufs3_ops, - name: "amufs3", -- block_sizes: AMUFS_BLOCK_SIZES - }; - PedFileSystemType _amufs4_type = { - next: NULL, - ops: &_amufs4_ops, - name: "amufs4", -- block_sizes: AMUFS_BLOCK_SIZES - }; - PedFileSystemType _amufs5_type = { - next: NULL, - ops: &_amufs5_ops, - name: "amufs5", -- block_sizes: AMUFS_BLOCK_SIZES - }; -diff --git a/libparted/fs/amiga/apfs.c b/libparted/fs/amiga/apfs.c -index 9f9e6e0..2d2cbe1 100644 ---- a/libparted/fs/amiga/apfs.c -+++ b/libparted/fs/amiga/apfs.c -@@ -48,6 +48,8 @@ _generic_apfs_probe (PedGeometry* geom, uint32_t kind) - - PED_ASSERT (geom != NULL); - PED_ASSERT (geom->dev != NULL); -+ if (geom->dev->sector_size != 512) -+ return NULL; - - /* Finds the blocksize and reserved values of the partition block */ - if (!(part = ped_malloc (PED_SECTOR_SIZE_DEFAULT*blocksize))) { -@@ -113,17 +115,13 @@ static PedFileSystemOps _apfs2_ops = { - probe: _apfs2_probe, - }; - --#define APFS_BLOCK_SIZES ((int[2]){512, 0}) -- - PedFileSystemType _apfs1_type = { - next: NULL, - ops: &_apfs1_ops, - name: "apfs1", -- block_sizes: APFS_BLOCK_SIZES - }; - PedFileSystemType _apfs2_type = { - next: NULL, - ops: &_apfs2_ops, - name: "apfs2", -- block_sizes: APFS_BLOCK_SIZES - }; -diff --git a/libparted/fs/amiga/asfs.c b/libparted/fs/amiga/asfs.c -index f7b4ed0..5824881 100644 ---- a/libparted/fs/amiga/asfs.c -+++ b/libparted/fs/amiga/asfs.c -@@ -62,6 +62,8 @@ _asfs_probe (PedGeometry* geom) - - PED_ASSERT (geom != NULL); - PED_ASSERT (geom->dev != NULL); -+ if (geom->dev->sector_size != 512) -+ return NULL; - - /* Finds the blocksize of the partition block */ - if (!(part = ped_malloc (PED_SECTOR_SIZE_DEFAULT*blocksize))) { -@@ -124,5 +126,4 @@ PedFileSystemType _asfs_type = { - next: NULL, - ops: &_asfs_ops, - name: "asfs", -- block_sizes: ((int[2]){512, 0}) - }; -diff --git a/libparted/fs/btrfs/btrfs.c b/libparted/fs/btrfs/btrfs.c -index e5abed6..8d76f6f 100644 ---- a/libparted/fs/btrfs/btrfs.c -+++ b/libparted/fs/btrfs/btrfs.c -@@ -62,7 +62,6 @@ static PedFileSystemType btrfs_type = { - next: NULL, - ops: &btrfs_ops, - name: "btrfs", -- block_sizes: ((int[2]){512, 0}) - }; - - void -diff --git a/libparted/fs/ext2/interface.c b/libparted/fs/ext2/interface.c -index 97220b7..ecafb62 100644 ---- a/libparted/fs/ext2/interface.c -+++ b/libparted/fs/ext2/interface.c -@@ -33,10 +33,12 @@ struct ext2_dev_handle* ext2_make_dev_handle_from_parted_geometry(PedGeometry* g - static PedGeometry* - _ext2_generic_probe (PedGeometry* geom, int expect_ext_ver) - { -- void *sb_v; -- if (!ped_geometry_read_alloc(geom, &sb_v, 2, 2)) -+ const int sectors = (4096 + geom->dev->sector_size - 1) / -+ geom->dev->sector_size; -+ char *sb_v = alloca (sectors * geom->dev->sector_size); -+ if (!ped_geometry_read(geom, sb_v, 0, sectors)) - return NULL; -- struct ext2_super_block *sb = sb_v; -+ struct ext2_super_block *sb = (struct ext2_super_block *)(sb_v + 1024); - - if (EXT2_SUPER_MAGIC(*sb) == EXT2_SUPER_MAGIC_CONST) { - PedSector block_size = 1 << (EXT2_SUPER_LOG_BLOCK_SIZE(*sb) + 1); -@@ -66,8 +68,6 @@ _ext2_generic_probe (PedGeometry* geom, int expect_ext_ver) - if (is_ext4) - is_ext3 = 0; - } -- free (sb); -- - if (expect_ext_ver == 2 && (is_ext3 || is_ext4)) - return NULL; - if (expect_ext_ver == 3 && !is_ext3) -@@ -94,9 +94,6 @@ _ext2_generic_probe (PedGeometry* geom, int expect_ext_ver) - block_count * block_size); - } - } -- else { -- free (sb); -- } - - return NULL; - } -@@ -131,27 +128,22 @@ static PedFileSystemOps _ext4_ops = { - probe: _ext4_probe, - }; - --#define EXT23_BLOCK_SIZES ((int[6]){512, 1024, 2048, 4096, 8192, 0}) -- - static PedFileSystemType _ext2_type = { - next: NULL, - ops: &_ext2_ops, - name: "ext2", -- block_sizes: EXT23_BLOCK_SIZES - }; - - static PedFileSystemType _ext3_type = { - next: NULL, - ops: &_ext3_ops, - name: "ext3", -- block_sizes: EXT23_BLOCK_SIZES - }; - - static PedFileSystemType _ext4_type = { - next: NULL, - ops: &_ext4_ops, - name: "ext4", -- block_sizes: EXT23_BLOCK_SIZES - }; - - void ped_file_system_ext2_init () -diff --git a/libparted/fs/fat/bootsector.c b/libparted/fs/fat/bootsector.c -index dacc79c..95a8412 100644 ---- a/libparted/fs/fat/bootsector.c -+++ b/libparted/fs/fat/bootsector.c -@@ -36,13 +36,14 @@ - * fat_boot_sector_probe_type() to work (or possibly crash on a divide-by-zero) - */ - int --fat_boot_sector_read (FatBootSector* bs, const PedGeometry *geom) -+fat_boot_sector_read (FatBootSector** bsp, const PedGeometry *geom) - { -- PED_ASSERT (bs != NULL); -+ PED_ASSERT (bsp != NULL); - PED_ASSERT (geom != NULL); - -- if (!ped_geometry_read (geom, bs, 0, 1)) -+ if (!ped_geometry_read_alloc (geom, (void **)bsp, 0, 1)) - return 0; -+ FatBootSector *bs = *bsp; - - if (PED_LE16_TO_CPU (bs->boot_sign) != 0xAA55) { - ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, -@@ -142,18 +143,6 @@ fat_boot_sector_analyse (FatBootSector* bs, PedFileSystem* fs) - - PED_ASSERT (bs != NULL); - -- if (PED_LE16_TO_CPU (bs->sector_size) != 512) { -- if (ped_exception_throw ( -- PED_EXCEPTION_BUG, -- PED_EXCEPTION_IGNORE_CANCEL, -- _("This file system has a logical sector size of %d. " -- "GNU Parted is known not to work properly with sector " -- "sizes other than 512 bytes."), -- (int) PED_LE16_TO_CPU (bs->sector_size)) -- != PED_EXCEPTION_IGNORE) -- return 0; -- } -- - fs_info->logical_sector_size = PED_LE16_TO_CPU (bs->sector_size) / 512; - - fs_info->sectors_per_track = PED_LE16_TO_CPU (bs->secs_track); -@@ -252,10 +241,10 @@ fat_boot_sector_analyse (FatBootSector* bs, PedFileSystem* fs) - fs_info->serial_number - = PED_LE32_TO_CPU (bs->u.fat32.serial_number); - fs_info->info_sector_offset -- = PED_LE16_TO_CPU (fs_info->boot_sector.u.fat32.info_sector) -+ = PED_LE16_TO_CPU (fs_info->boot_sector->u.fat32.info_sector) - * fs_info->logical_sector_size; - fs_info->boot_sector_backup_offset -- = PED_LE16_TO_CPU (fs_info->boot_sector.u.fat32.backup_sector) -+ = PED_LE16_TO_CPU (fs_info->boot_sector->u.fat32.backup_sector) - * fs_info->logical_sector_size; - fs_info->root_cluster - = PED_LE32_TO_CPU (bs->u.fat32.root_dir_cluster); -@@ -280,30 +269,3 @@ fat_boot_sector_analyse (FatBootSector* bs, PedFileSystem* fs) - = fs_info->cluster_size / sizeof (FatDirEntry); - return 1; - } -- --#ifndef DISCOVER_ONLY -- --int --fat_info_sector_read (FatInfoSector* is, const PedFileSystem* fs) --{ -- FatSpecific* fs_info = FAT_SPECIFIC (fs); -- int status; -- -- PED_ASSERT (is != NULL); -- -- if (!ped_geometry_read (fs->geom, is, fs_info->info_sector_offset, 1)) -- return 0; -- -- if (PED_LE32_TO_CPU (is->signature_2) != FAT32_INFO_MAGIC2) { -- status = ped_exception_throw (PED_EXCEPTION_WARNING, -- PED_EXCEPTION_IGNORE_CANCEL, -- _("The information sector has the wrong " -- "signature (%x). Select cancel for now, " -- "and send in a bug report. If you're " -- "desperate, it's probably safe to ignore."), -- PED_LE32_TO_CPU (is->signature_2)); -- if (status == PED_EXCEPTION_CANCEL) return 0; -- } -- return 1; --} --#endif /* !DISCOVER_ONLY */ -diff --git a/libparted/fs/fat/bootsector.h b/libparted/fs/fat/bootsector.h -index 3f84742..449427a 100644 ---- a/libparted/fs/fat/bootsector.h -+++ b/libparted/fs/fat/bootsector.h -@@ -116,11 +116,10 @@ struct __attribute__ ((packed)) _FatInfoSector { - uint16_t signature_3; /* should be 0xaa55 */ - }; - --int fat_boot_sector_read (FatBootSector* bs, const PedGeometry* geom); -+int fat_boot_sector_read (FatBootSector** bs, const PedGeometry* geom); - FatType fat_boot_sector_probe_type (const FatBootSector* bs, - const PedGeometry* geom); - int fat_boot_sector_analyse (FatBootSector* bs, PedFileSystem* fs); - --int fat_info_sector_read (FatInfoSector* is, const PedFileSystem* fs); - - #endif /* PED_FAT_BOOTSECTOR_H */ -diff --git a/libparted/fs/fat/fat.c b/libparted/fs/fat/fat.c -index 95cbc8d..5a409b2 100644 ---- a/libparted/fs/fat/fat.c -+++ b/libparted/fs/fat/fat.c -@@ -34,7 +34,9 @@ fat_alloc (const PedGeometry* geom) - fs->type_specific = (FatSpecific*) ped_malloc (sizeof (FatSpecific)); - if (!fs->type_specific) - goto error_free_fs; -- -+ FatSpecific* fs_info = (FatSpecific*) fs->type_specific; -+ fs_info->boot_sector = NULL; -+ fs_info->info_sector = NULL; - fs->geom = ped_geometry_duplicate (geom); - if (!fs->geom) - goto error_free_type_specific; -@@ -53,6 +55,8 @@ error: - void - fat_free (PedFileSystem* fs) - { -+ FatSpecific* fs_info = (FatSpecific*) fs->type_specific; -+ free (fs_info->boot_sector); - ped_geometry_destroy (fs->geom); - free (fs->type_specific); - free (fs); -@@ -72,7 +76,7 @@ fat_probe (PedGeometry* geom, FatType* fat_type) - - if (!fat_boot_sector_read (&fs_info->boot_sector, geom)) - goto error_free_fs; -- if (!fat_boot_sector_analyse (&fs_info->boot_sector, fs)) -+ if (!fat_boot_sector_analyse (fs_info->boot_sector, fs)) - goto error_free_fs; - - *fat_type = fs_info->fat_type; -@@ -124,20 +128,16 @@ static PedFileSystemOps fat32_ops = { - probe: fat_probe_fat32, - }; - --#define FAT_BLOCK_SIZES ((int[2]){512, 0}) -- - PedFileSystemType fat16_type = { - next: NULL, - ops: &fat16_ops, - name: "fat16", -- block_sizes: FAT_BLOCK_SIZES - }; - - PedFileSystemType fat32_type = { - next: NULL, - ops: &fat32_ops, - name: "fat32", -- block_sizes: FAT_BLOCK_SIZES - }; - - void -diff --git a/libparted/fs/fat/fat.h b/libparted/fs/fat/fat.h -index 437a020..2265871 100644 ---- a/libparted/fs/fat/fat.h -+++ b/libparted/fs/fat/fat.h -@@ -84,8 +84,8 @@ struct __attribute__ ((packed)) _FatDirEntry { - }; - - struct _FatSpecific { -- FatBootSector boot_sector; /* structure of boot sector */ -- FatInfoSector info_sector; /* fat32-only information sector */ -+ FatBootSector *boot_sector; /* structure of boot sector */ -+ FatInfoSector *info_sector; /* fat32-only information sector */ - - int logical_sector_size; /* illogical sector size :-) */ - PedSector sector_count; -diff --git a/libparted/fs/hfs/hfs.c b/libparted/fs/hfs/hfs.c -index 40c8173..e5396b2 100644 ---- a/libparted/fs/hfs/hfs.c -+++ b/libparted/fs/hfs/hfs.c -@@ -44,10 +44,6 @@ uint8_t* hfsp_block = NULL; - unsigned hfs_block_count; - unsigned hfsp_block_count; - --#define HFS_BLOCK_SIZES ((int[2]){512, 0}) --#define HFSP_BLOCK_SIZES ((int[2]){512, 0}) --#define HFSX_BLOCK_SIZES ((int[2]){512, 0}) -- - static PedFileSystemOps hfs_ops = { - probe: hfs_probe, - }; -@@ -65,21 +61,18 @@ static PedFileSystemType hfs_type = { - next: NULL, - ops: &hfs_ops, - name: "hfs", -- block_sizes: HFS_BLOCK_SIZES - }; - - static PedFileSystemType hfsplus_type = { - next: NULL, - ops: &hfsplus_ops, - name: "hfs+", -- block_sizes: HFSP_BLOCK_SIZES - }; - - static PedFileSystemType hfsx_type = { - next: NULL, - ops: &hfsx_ops, - name: "hfsx", -- block_sizes: HFSX_BLOCK_SIZES - }; - - void -diff --git a/libparted/fs/hfs/probe.c b/libparted/fs/hfs/probe.c -index ad79a64..c4dca5e 100644 ---- a/libparted/fs/hfs/probe.c -+++ b/libparted/fs/hfs/probe.c -@@ -62,7 +62,6 @@ it is in fact a wrapper to an HFS+ volume */ - PedGeometry* - hfs_and_wrapper_probe (PedGeometry* geom) - { -- uint8_t buf[PED_SECTOR_SIZE_DEFAULT]; - HfsMasterDirectoryBlock *mdb; - PedGeometry* geom_ret; - PedSector search, max; -@@ -70,18 +69,22 @@ hfs_and_wrapper_probe (PedGeometry* geom) - PED_ASSERT (geom != NULL); - PED_ASSERT (hfsc_can_use_geom (geom)); - -- mdb = (HfsMasterDirectoryBlock *) buf; -+ const int sectors = ((3 * 512) + geom->dev->sector_size - 1) / -+ geom->dev->sector_size; -+ char * buf = alloca (sectors * geom->dev->sector_size); -+ -+ mdb = (HfsMasterDirectoryBlock *)(buf+1024); - - /* is 5 an intelligent value ? */ - if ((geom->length < 5) -- || (!ped_geometry_read (geom, buf, 2, 1)) -+ || (!ped_geometry_read (geom, buf, 0, sectors)) - || (mdb->signature != PED_CPU_TO_BE16 (HFS_SIGNATURE)) ) - return NULL; - - search = ((PedSector) PED_BE16_TO_CPU (mdb->start_block) - + ((PedSector) PED_BE16_TO_CPU (mdb->total_blocks) -- * (PED_BE32_TO_CPU (mdb->block_size) / PED_SECTOR_SIZE_DEFAULT ))); -- max = search + (PED_BE32_TO_CPU (mdb->block_size) / PED_SECTOR_SIZE_DEFAULT); -+ * (PED_BE32_TO_CPU (mdb->block_size) / geom->dev->sector_size))); -+ max = search + (PED_BE32_TO_CPU (mdb->block_size) / geom->dev->sector_size); - if ((search < 0) - || !(geom_ret = ped_geometry_new (geom->dev, geom->start, search + 2))) - return NULL; -diff --git a/libparted/fs/jfs/jfs.c b/libparted/fs/jfs/jfs.c -index 803c241..c271285 100644 ---- a/libparted/fs/jfs/jfs.c -+++ b/libparted/fs/jfs/jfs.c -@@ -25,7 +25,7 @@ - #include "jfs_types.h" - #include "jfs_superblock.h" - --#define JFS_SUPER_SECTOR 64 -+#define JFS_SUPER_OFFSET 32768 - - #if ENABLE_NLS - # include -@@ -34,31 +34,23 @@ - # define _(String) (String) - #endif /* ENABLE_NLS */ - --#define JFS_BLOCK_SIZES ((int[2]){512, 0}) -- - static PedGeometry* - jfs_probe (PedGeometry* geom) - { -- union { -- struct superblock sb; -- char bytes[512]; -- } buf; -- -- /* FIXME: for now, don't even try to deal with larger sector size. */ -- if (geom->dev->sector_size != PED_SECTOR_SIZE_DEFAULT) -- return NULL; -+ struct superblock *sb = (struct superblock *)alloca (geom->dev->sector_size); - -- if (geom->length < JFS_SUPER_SECTOR + 1) -+ if (geom->length * geom->dev->sector_size < JFS_SUPER_OFFSET) - return NULL; -- if (!ped_geometry_read (geom, &buf, JFS_SUPER_SECTOR, 1)) -+ if (!ped_geometry_read (geom, sb, JFS_SUPER_OFFSET / geom->dev->sector_size, 1)) - return NULL; - -- if (strncmp (buf.sb.s_magic, JFS_MAGIC, 4) == 0) { -- PedSector block_size = PED_LE32_TO_CPU (buf.sb.s_pbsize) / 512; -- PedSector block_count = PED_LE64_TO_CPU (buf.sb.s_size); -- -+ if (strncmp (sb->s_magic, JFS_MAGIC, 4) == 0) { -+ PedSector block_size = PED_LE32_TO_CPU (sb->s_pbsize); -+ PedSector block_count = PED_LE64_TO_CPU (sb->s_size); -+ /* apparently jfs is retarded and always claims 512 byte -+ sectors, with the block count as a multiple of that */ - return ped_geometry_new (geom->dev, geom->start, -- block_size * block_count); -+ block_size * block_count / geom->dev->sector_size); - } else { - return NULL; - } -@@ -72,7 +64,6 @@ static PedFileSystemType jfs_type = { - next: NULL, - ops: &jfs_ops, - name: "jfs", -- block_sizes: JFS_BLOCK_SIZES - }; - - void -diff --git a/libparted/fs/linux_swap/linux_swap.c b/libparted/fs/linux_swap/linux_swap.c -index bbc034d..0621fa0 100644 ---- a/libparted/fs/linux_swap/linux_swap.c -+++ b/libparted/fs/linux_swap/linux_swap.c -@@ -86,11 +86,6 @@ _generic_swap_probe (PedGeometry* geom, int kind) - PedGeometry* probed_geom; - PedSector length; - -- /* Fail the swap-file-system-recognizing test when sector size -- is not the default. */ -- if (geom->dev->sector_size != PED_SECTOR_SIZE_DEFAULT) -- return NULL; -- - switch (kind) { - /* Check for old style swap partitions. */ - case 0: -@@ -132,30 +127,18 @@ error: - - - static int --swap_init (PedFileSystem* fs, int fresh) -+swap_init (PedFileSystem* fs) - { - SwapSpecific* fs_info = SWAP_SPECIFIC (fs); - -- fs_info->page_sectors = getpagesize () / 512; -+ fs_info->page_sectors = getpagesize () / fs->geom->dev->sector_size; - fs_info->page_count = fs->geom->length / fs_info->page_sectors; - fs_info->version = 1; - fs_info->max_bad_pages = (getpagesize() - - sizeof (SwapNewHeader)) / 4; - -- if (fresh) { -- uuid_t uuid_dat; -- -- memset (fs_info->header, 0, getpagesize()); -- -- /* version is always 1 here */ -- uuid_generate (uuid_dat); -- memcpy (fs_info->header->new.sws_uuid, uuid_dat, -- sizeof (fs_info->header->new.sws_uuid)); -- return 1; -- } -- else -- return ped_geometry_read (fs->geom, fs_info->header, -- 0, fs_info->page_sectors); -+ return ped_geometry_read (fs->geom, fs_info->header, -+ 0, fs_info->page_sectors); - } - - -@@ -174,7 +157,7 @@ swap_alloc (PedGeometry* geom) - goto error_free_fs; - - fs_info = SWAP_SPECIFIC (fs); -- fs_info->header = ped_malloc (getpagesize()); -+ fs_info->header = ped_malloc (PED_MAX(getpagesize(), geom->dev->sector_size)); - if (!fs_info->header) - goto error_free_type_specific; - -@@ -225,7 +208,7 @@ _swap_v0_open (PedGeometry* geom) - fs = swap_alloc (geom); - if (!fs) - goto error; -- swap_init (fs, 0); -+ swap_init (fs); - - fs_info = SWAP_SPECIFIC (fs); - if (!ped_geometry_read (fs->geom, fs_info->header, 0, -@@ -267,12 +250,7 @@ _swap_v1_open (PedGeometry* geom) - fs = swap_alloc (geom); - if (!fs) - goto error; --/* swap_init (fs, 0); */ -- --/* fs_info = SWAP_SPECIFIC (fs); */ --/* if (!ped_geometry_read (fs->geom, fs_info->header, 0, */ --/* fs_info->page_sectors)) */ -- if (!swap_init(fs, 0)) -+ if (!swap_init(fs)) - goto error_free_fs; - - fs_info = SWAP_SPECIFIC (fs); -@@ -311,7 +289,7 @@ _swap_swsusp_open (PedGeometry* geom) - if (!fs) - goto error; - fs->type = &_swap_swsusp_type; -- swap_init (fs, 0); -+ swap_init (fs); - - fs_info = SWAP_SPECIFIC (fs); - if (!ped_geometry_read (fs->geom, fs_info->header, 0, -@@ -378,21 +356,18 @@ static PedFileSystemType _swap_v0_type = { - next: NULL, - ops: &_swap_v0_ops, - name: "linux-swap(v0)", -- block_sizes: LINUXSWAP_BLOCK_SIZES - }; - - static PedFileSystemType _swap_v1_type = { - next: NULL, - ops: &_swap_v1_ops, - name: "linux-swap(v1)", -- block_sizes: LINUXSWAP_BLOCK_SIZES - }; - - static PedFileSystemType _swap_swsusp_type = { - next: NULL, - ops: &_swap_swsusp_ops, - name: "swsusp", -- block_sizes: LINUXSWAP_BLOCK_SIZES - }; - - void -diff --git a/libparted/fs/nilfs2/nilfs2.c b/libparted/fs/nilfs2/nilfs2.c -index bb0a84e..0ec5867 100644 ---- a/libparted/fs/nilfs2/nilfs2.c -+++ b/libparted/fs/nilfs2/nilfs2.c -@@ -103,38 +103,31 @@ is_valid_nilfs_sb(struct nilfs2_super_block *sb) - PedGeometry* - nilfs2_probe (PedGeometry* geom) - { -- void *sb_v; -- void *sb2_v; - struct nilfs2_super_block *sb = NULL; - struct nilfs2_super_block *sb2 = NULL; -- PedSector length = geom->length; -+ PedSector length = geom->length * (geom->dev->sector_size / 512); - -- /* ignore if sector size is not 512bytes for now */ -- if (geom->dev->sector_size != PED_SECTOR_SIZE_DEFAULT) -- return NULL; -- -- PedSector sb2off = NILFS_SB2_OFFSET(length); -+ PedSector sb2off = NILFS_SB2_OFFSET(length) / (geom->dev->sector_size / 512); - if (sb2off <= 2) - return NULL; -+ const int sectors = (4096 + geom->dev->sector_size - 1) / -+ geom->dev->sector_size; -+ char *buf = alloca (sectors * geom->dev->sector_size); -+ void *buff2 = alloca (geom->dev->sector_size); - -- if (ped_geometry_read_alloc(geom, &sb_v, 2, 1)) -- sb = sb_v; -- -- if (ped_geometry_read_alloc(geom, &sb2_v, sb2off, 1)) -- sb2 = sb2_v; -+ if (ped_geometry_read(geom, buf, 0, sectors)) -+ sb = (struct nilfs2_super_block *)(buf+1024); -+ if (ped_geometry_read(geom, buff2, sb2off, 1)) -+ sb2 = buff2; - - if ((!sb || !is_valid_nilfs_sb(sb)) && -- (!sb2 || !is_valid_nilfs_sb(sb2)) ) { -- free(sb); -- free(sb2); -+ (!sb2 || !is_valid_nilfs_sb(sb2)) ) - return NULL; -- } - - /* reserve 4k bytes for secondary superblock */ -- length = sb2off + 8; -+ length = sb2off + ((4096 + geom->dev->sector_size - 1) / -+ geom->dev->sector_size); - -- free(sb); -- free(sb2); - return ped_geometry_new(geom->dev, geom->start, length); - } - -@@ -142,13 +135,10 @@ static PedFileSystemOps nilfs2_ops = { - probe: nilfs2_probe, - }; - --#define NILFS2_BLOCK_SIZES ((int[5]){1024, 2048, 4096, 8192, 0}) -- - static PedFileSystemType nilfs2_type = { - next: NULL, - ops: &nilfs2_ops, - name: "nilfs2", -- block_sizes: NILFS2_BLOCK_SIZES - }; - - void -diff --git a/libparted/fs/ntfs/ntfs.c b/libparted/fs/ntfs/ntfs.c -index 05d7f36..3ba2683 100644 ---- a/libparted/fs/ntfs/ntfs.c -+++ b/libparted/fs/ntfs/ntfs.c -@@ -30,24 +30,22 @@ - - #include - --#define NTFS_BLOCK_SIZES ((int[2]){512, 0}) -- - #define NTFS_SIGNATURE "NTFS" - - static PedGeometry* - ntfs_probe (PedGeometry* geom) - { -- char buf[512]; -+ char *buf = alloca (geom->dev->sector_size); -+ PedGeometry *newg = NULL; - -- if (!ped_geometry_read (geom, buf, 0, 1)) -+ if (!ped_geometry_read(geom, buf, 0, 1)) - return 0; - - if (strncmp (NTFS_SIGNATURE, buf + 3, strlen (NTFS_SIGNATURE)) == 0) -- return ped_geometry_new (geom->dev, geom->start, -+ newg = ped_geometry_new (geom->dev, geom->start, - PED_LE64_TO_CPU (*(uint64_t*) - (buf + 0x28))); -- else -- return NULL; -+ return newg; - } - - static PedFileSystemOps ntfs_ops = { -@@ -58,7 +56,6 @@ static PedFileSystemType ntfs_type = { - next: NULL, - ops: &ntfs_ops, - name: "ntfs", -- block_sizes: NTFS_BLOCK_SIZES - }; - - void -diff --git a/libparted/fs/r/fat/bootsector.c b/libparted/fs/r/fat/bootsector.c -index 3aff1d7..fcb9782 100644 ---- a/libparted/fs/r/fat/bootsector.c -+++ b/libparted/fs/r/fat/bootsector.c -@@ -36,14 +36,14 @@ - * fat_boot_sector_probe_type() to work (or possibly crash on a divide-by-zero) - */ - int --fat_boot_sector_read (FatBootSector* bs, const PedGeometry *geom) -+fat_boot_sector_read (FatBootSector** bsp, const PedGeometry *geom) - { -- PED_ASSERT (bs != NULL); -+ PED_ASSERT (bsp != NULL); - PED_ASSERT (geom != NULL); - -- if (!ped_geometry_read (geom, bs, 0, 1)) -+ if (!ped_geometry_read_alloc (geom, (void **)bsp, 0, 1)) - return 0; -- -+ FatBootSector *bs = *bsp; - if (PED_LE16_TO_CPU (bs->boot_sign) != 0xAA55) { - ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, - _("File system has an invalid signature for a FAT " -@@ -250,10 +250,10 @@ fat_boot_sector_analyse (FatBootSector* bs, PedFileSystem* fs) - fs_info->serial_number - = PED_LE32_TO_CPU (bs->u.fat32.serial_number); - fs_info->info_sector_offset -- = PED_LE16_TO_CPU (fs_info->boot_sector.u.fat32.info_sector) -+ = PED_LE16_TO_CPU (fs_info->boot_sector->u.fat32.info_sector) - * fs_info->logical_sector_size; - fs_info->boot_sector_backup_offset -- = PED_LE16_TO_CPU (fs_info->boot_sector.u.fat32.backup_sector) -+ = PED_LE16_TO_CPU (fs_info->boot_sector->u.fat32.backup_sector) - * fs_info->logical_sector_size; - fs_info->root_cluster - = PED_LE32_TO_CPU (bs->u.fat32.root_dir_cluster); -@@ -292,11 +292,13 @@ fat_boot_sector_set_boot_code (FatBootSector* bs) - } - - int --fat_boot_sector_generate (FatBootSector* bs, const PedFileSystem* fs) -+fat_boot_sector_generate (FatBootSector** bsp, const PedFileSystem* fs) - { - FatSpecific* fs_info = FAT_SPECIFIC (fs); - -- PED_ASSERT (bs != NULL); -+ PED_ASSERT (bsp != NULL); -+ *bsp = ped_malloc (fs->geom->dev->sector_size); -+ FatBootSector *bs = *bsp; - - memcpy (bs->system_id, "MSWIN4.1", 8); - bs->sector_size = PED_CPU_TO_LE16 (fs_info->logical_sector_size * 512); -@@ -388,16 +390,16 @@ fat_boot_sector_write (const FatBootSector* bs, PedFileSystem* fs) - } - - int --fat_info_sector_read (FatInfoSector* is, const PedFileSystem* fs) -+fat_info_sector_read (FatInfoSector** isp, const PedFileSystem* fs) - { - FatSpecific* fs_info = FAT_SPECIFIC (fs); - int status; - -- PED_ASSERT (is != NULL); -+ PED_ASSERT (isp != NULL); - -- if (!ped_geometry_read (fs->geom, is, fs_info->info_sector_offset, 1)) -+ if (!ped_geometry_read_alloc (fs->geom, (void **)isp, fs_info->info_sector_offset, 1)) - return 0; -- -+ FatInfoSector *is = *isp; - if (PED_LE32_TO_CPU (is->signature_2) != FAT32_INFO_MAGIC2) { - status = ped_exception_throw (PED_EXCEPTION_WARNING, - PED_EXCEPTION_IGNORE_CANCEL, -@@ -412,11 +414,13 @@ fat_info_sector_read (FatInfoSector* is, const PedFileSystem* fs) - } - - int --fat_info_sector_generate (FatInfoSector* is, const PedFileSystem* fs) -+fat_info_sector_generate (FatInfoSector** isp, const PedFileSystem* fs) - { - FatSpecific* fs_info = FAT_SPECIFIC (fs); - -- PED_ASSERT (is != NULL); -+ PED_ASSERT (isp != NULL); -+ *isp = ped_malloc (fs->geom->dev->sector_size); -+ FatInfoSector *is = *isp; - - fat_table_count_stats (fs_info->fat); - -diff --git a/libparted/fs/r/fat/bootsector.h b/libparted/fs/r/fat/bootsector.h -index ec367c3..6e8b9ce 100644 ---- a/libparted/fs/r/fat/bootsector.h -+++ b/libparted/fs/r/fat/bootsector.h -@@ -116,16 +116,16 @@ struct __attribute__ ((packed)) _FatInfoSector { - uint16_t signature_3; /* should be 0xaa55 */ - }; - --int fat_boot_sector_read (FatBootSector* bs, const PedGeometry* geom); -+int fat_boot_sector_read (FatBootSector** bs, const PedGeometry* geom); - FatType fat_boot_sector_probe_type (const FatBootSector* bs, - const PedGeometry* geom); - int fat_boot_sector_analyse (FatBootSector* bs, PedFileSystem* fs); - int fat_boot_sector_set_boot_code (FatBootSector* bs); --int fat_boot_sector_generate (FatBootSector* bs, const PedFileSystem* fs); -+int fat_boot_sector_generate (FatBootSector** bs, const PedFileSystem* fs); - int fat_boot_sector_write (const FatBootSector* bs, PedFileSystem* fs); - --int fat_info_sector_read (FatInfoSector* is, const PedFileSystem* fs); --int fat_info_sector_generate (FatInfoSector* is, const PedFileSystem* fs); -+int fat_info_sector_read (FatInfoSector** is, const PedFileSystem* fs); -+int fat_info_sector_generate (FatInfoSector** is, const PedFileSystem* fs); - int fat_info_sector_write (const FatInfoSector* is, PedFileSystem* fs); - - #endif /* PED_FAT_BOOTSECTOR_H */ -diff --git a/libparted/fs/r/fat/fat.c b/libparted/fs/r/fat/fat.c -index c8e4552..fdc1ecc 100644 ---- a/libparted/fs/r/fat/fat.c -+++ b/libparted/fs/r/fat/fat.c -@@ -112,19 +112,22 @@ fat_set_frag_sectors (PedFileSystem* fs, PedSector frag_sectors) - int - fat_clobber (PedGeometry* geom) - { -- FatBootSector boot_sector; -+ FatBootSector *boot_sector; -+ int ok; - - if (!fat_boot_sector_read (&boot_sector, geom)) - return 1; - -- boot_sector.system_id[0] = 0; -- boot_sector.boot_sign = 0; -- if (boot_sector.u.fat16.fat_name[0] == 'F') -- boot_sector.u.fat16.fat_name[0] = 0; -- if (boot_sector.u.fat32.fat_name[0] == 'F') -- boot_sector.u.fat32.fat_name[0] = 0; -+ boot_sector->system_id[0] = 0; -+ boot_sector->boot_sign = 0; -+ if (boot_sector->u.fat16.fat_name[0] == 'F') -+ boot_sector->u.fat16.fat_name[0] = 0; -+ if (boot_sector->u.fat32.fat_name[0] == 'F') -+ boot_sector->u.fat32.fat_name[0] = 0; - -- return ped_geometry_write (geom, &boot_sector, 0, 1); -+ ok = ped_geometry_write (geom, boot_sector, 0, 1); -+ free (boot_sector); -+ return ok; - } - - static int -@@ -163,7 +166,7 @@ fat_open (PedGeometry* geom) - - if (!fat_boot_sector_read (&fs_info->boot_sector, geom)) - goto error_free_fs; -- if (!fat_boot_sector_analyse (&fs_info->boot_sector, fs)) -+ if (!fat_boot_sector_analyse (fs_info->boot_sector, fs)) - goto error_free_fs; - fs->type = (fs_info->fat_type == FAT_TYPE_FAT16) - ? &fat16_type -@@ -303,16 +306,16 @@ fat_create (PedGeometry* geom, FatType fat_type, PedTimer* timer) - - fs_info->serial_number = generate_random_uint32 (); - -- if (!fat_boot_sector_set_boot_code (&fs_info->boot_sector)) -+ if (!fat_boot_sector_set_boot_code (fs_info->boot_sector)) - goto error_free_buffers; - if (!fat_boot_sector_generate (&fs_info->boot_sector, fs)) - goto error_free_buffers; -- if (!fat_boot_sector_write (&fs_info->boot_sector, fs)) -+ if (!fat_boot_sector_write (fs_info->boot_sector, fs)) - goto error_free_buffers; - if (fs_info->fat_type == FAT_TYPE_FAT32) { - if (!fat_info_sector_generate (&fs_info->info_sector, fs)) - goto error_free_buffers; -- if (!fat_info_sector_write (&fs_info->info_sector, fs)) -+ if (!fat_info_sector_write (fs_info->info_sector, fs)) - goto error_free_buffers; - } - -@@ -469,7 +472,7 @@ fat_check (PedFileSystem* fs, PedTimer* timer) - - if (fs_info->fat_type == FAT_TYPE_FAT32) { - info_free_clusters -- = PED_LE32_TO_CPU (fs_info->info_sector.free_clusters); -+ = PED_LE32_TO_CPU (fs_info->info_sector->free_clusters); - if (info_free_clusters != (FatCluster) -1 - && info_free_clusters != fs_info->fat->free_cluster_count) { - if (ped_exception_throw (PED_EXCEPTION_WARNING, -diff --git a/libparted/fs/r/fat/fat.h b/libparted/fs/r/fat/fat.h -index d2ac2aa..943c5e5 100644 ---- a/libparted/fs/r/fat/fat.h -+++ b/libparted/fs/r/fat/fat.h -@@ -77,8 +77,8 @@ struct __attribute__ ((packed)) _FatDirEntry { - }; - - struct _FatSpecific { -- FatBootSector boot_sector; /* structure of boot sector */ -- FatInfoSector info_sector; /* fat32-only information sector */ -+ FatBootSector *boot_sector; /* structure of boot sector */ -+ FatInfoSector *info_sector; /* fat32-only information sector */ - - int logical_sector_size; /* illogical sector size :-) */ - PedSector sector_count; -diff --git a/libparted/fs/r/fat/resize.c b/libparted/fs/r/fat/resize.c -index 2b68a8b..f3439ac 100644 ---- a/libparted/fs/r/fat/resize.c -+++ b/libparted/fs/r/fat/resize.c -@@ -857,10 +857,10 @@ fat_resize (PedFileSystem* fs, PedGeometry* geom, PedTimer* timer) - - _copy_hidden_sectors (ctx); - fat_boot_sector_generate (&new_fs_info->boot_sector, new_fs); -- fat_boot_sector_write (&new_fs_info->boot_sector, new_fs); -+ fat_boot_sector_write (new_fs_info->boot_sector, new_fs); - if (new_fs_info->fat_type == FAT_TYPE_FAT32) { - fat_info_sector_generate (&new_fs_info->info_sector, new_fs); -- fat_info_sector_write (&new_fs_info->info_sector, new_fs); -+ fat_info_sector_write (new_fs_info->info_sector, new_fs); - } - - if (!resize_context_assimilate (ctx)) -diff --git a/libparted/fs/r/fat/table.c b/libparted/fs/r/fat/table.c -index 974dea8..62bc3b3 100644 ---- a/libparted/fs/r/fat/table.c -+++ b/libparted/fs/r/fat/table.c -@@ -129,7 +129,7 @@ fat_table_read (FatTable* ft, const PedFileSystem* fs, int table_num) - fs_info->fat_sectors)) - return 0; - -- if ( *((unsigned char*) ft->table) != fs_info->boot_sector.media) { -+ if ( *((unsigned char*) ft->table) != fs_info->boot_sector->media) { - if (ped_exception_throw ( - PED_EXCEPTION_ERROR, - PED_EXCEPTION_IGNORE_CANCEL, -@@ -137,7 +137,7 @@ fat_table_read (FatTable* ft, const PedFileSystem* fs, int table_num) - "media %x. You should probably run scandisk."), - (int) table_num + 1, - (int) *((unsigned char*) ft->table), -- (int) fs_info->boot_sector.media) -+ (int) fs_info->boot_sector->media) - != PED_EXCEPTION_IGNORE) - return 0; - } -diff --git a/libparted/fs/reiserfs/reiserfs.c b/libparted/fs/reiserfs/reiserfs.c -index 21d4272..838b2fb 100644 ---- a/libparted/fs/reiserfs/reiserfs.c -+++ b/libparted/fs/reiserfs/reiserfs.c -@@ -46,8 +46,6 @@ - - #include "reiserfs.h" - --#define REISERFS_BLOCK_SIZES ((int[2]){512, 0}) -- - static PedSector reiserfs_super_offset[] = { 128, 16, -1 }; - static PedFileSystemType* reiserfs_type; - -@@ -57,29 +55,29 @@ static PedFileSystemType* reiserfs_type; - static PedGeometry *reiserfs_probe(PedGeometry *geom) - { - int i; -- reiserfs_super_block_t sb; - - PED_ASSERT(geom != NULL); -+ reiserfs_super_block_t *sb = -+ (reiserfs_super_block_t *)alloca (geom->dev->sector_size); - - for (i = 0; reiserfs_super_offset[i] != -1; i++) { - if (reiserfs_super_offset[i] >= geom->length) - continue; -- if (!ped_geometry_read (geom, &sb, reiserfs_super_offset[i], 1)) -+ if (!ped_geometry_read (geom, sb, reiserfs_super_offset[i], 1)) - continue; - -- if (strncmp(REISERFS_SIGNATURE, sb.s_magic, -+ if (strncmp(REISERFS_SIGNATURE, sb->s_magic, - strlen(REISERFS_SIGNATURE)) == 0 -- || strncmp(REISER2FS_SIGNATURE, sb.s_magic, -+ || strncmp(REISER2FS_SIGNATURE, sb->s_magic, - strlen(REISER2FS_SIGNATURE)) == 0 -- || strncmp(REISER3FS_SIGNATURE, sb.s_magic, -+ || strncmp(REISER3FS_SIGNATURE, sb->s_magic, - strlen(REISER3FS_SIGNATURE)) == 0) { - PedSector block_size; - PedSector block_count; - -- block_size = PED_LE16_TO_CPU(sb.s_blocksize) -- / PED_SECTOR_SIZE_DEFAULT; -- block_count = PED_LE32_TO_CPU(sb.s_block_count); -- -+ block_size = PED_LE16_TO_CPU(sb->s_blocksize) -+ / geom->dev->sector_size; -+ block_count = PED_LE32_TO_CPU(sb->s_block_count); - return ped_geometry_new(geom->dev, geom->start, - block_size * block_count); - } -@@ -88,8 +86,6 @@ static PedGeometry *reiserfs_probe(PedGeometry *geom) - } - - --#define REISER_BLOCK_SIZES ((int[]){512, 1024, 2048, 4096, 8192, 0}) -- - static PedFileSystemOps reiserfs_simple_ops = { - probe: reiserfs_probe, - }; -@@ -98,7 +94,6 @@ static PedFileSystemType reiserfs_simple_type = { - next: NULL, - ops: &reiserfs_simple_ops, - name: "reiserfs", -- block_sizes: REISER_BLOCK_SIZES - }; - - void ped_file_system_reiserfs_init() -diff --git a/libparted/fs/ufs/ufs.c b/libparted/fs/ufs/ufs.c -index b668d7b..a75c082 100644 ---- a/libparted/fs/ufs/ufs.c -+++ b/libparted/fs/ufs/ufs.c -@@ -34,10 +34,6 @@ - #include - #include - --#define SUN_UFS_BLOCK_SIZES ((int[2]){512, 0}) --#define HP_UFS_BLOCK_SIZES ((int[2]){512, 0}) -- -- - /* taken from ufs_fs.h in Linux */ - #define UFS_MAXNAMLEN 255 - #define UFS_MAXMNTLEN 512 -@@ -178,24 +174,26 @@ struct ufs_super_block { - static PedGeometry* - ufs_probe_sun (PedGeometry* geom) - { -- int8_t buf[512 * 3]; -+ const int sectors = ((3 * 512) + geom->dev->sector_size - 1) / -+ geom->dev->sector_size; -+ char * buf = alloca (sectors * geom->dev->sector_size); - struct ufs_super_block *sb; - - if (geom->length < 5) - return 0; -- if (!ped_geometry_read (geom, buf, 16, 3)) -+ if (!ped_geometry_read (geom, buf, 16 * 512 / geom->dev->sector_size, sectors)) - return 0; - - sb = (struct ufs_super_block *)buf; - - if (PED_BE32_TO_CPU(sb->fs_magic) == UFS_MAGIC) { -- PedSector block_size = PED_BE32_TO_CPU(sb->fs_bsize) / 512; -+ PedSector block_size = PED_BE32_TO_CPU(sb->fs_bsize) / geom->dev->sector_size; - PedSector block_count = PED_BE32_TO_CPU(sb->fs_size); - return ped_geometry_new (geom->dev, geom->start, - block_size * block_count); - } - if (PED_LE32_TO_CPU(sb->fs_magic) == UFS_MAGIC) { -- PedSector block_size = PED_LE32_TO_CPU(sb->fs_bsize) / 512; -+ PedSector block_size = PED_LE32_TO_CPU(sb->fs_bsize) / geom->dev->sector_size; - PedSector block_count = PED_LE32_TO_CPU(sb->fs_size); - return ped_geometry_new (geom->dev, geom->start, - block_size * block_count); -@@ -206,14 +204,17 @@ ufs_probe_sun (PedGeometry* geom) - static PedGeometry* - ufs_probe_hp (PedGeometry* geom) - { -- int8_t buf[1536]; - struct ufs_super_block *sb; - PedSector block_size; - PedSector block_count; - - if (geom->length < 5) - return 0; -- if (!ped_geometry_read (geom, buf, 16, 3)) -+ const int sectors = ((3 * 512) + geom->dev->sector_size - 1) / -+ geom->dev->sector_size; -+ char * buf = alloca (sectors * geom->dev->sector_size); -+ -+ if (!ped_geometry_read (geom, buf, 16 * 512 / geom->dev->sector_size, sectors)) - return 0; - - sb = (struct ufs_super_block *)buf; -@@ -223,7 +224,7 @@ ufs_probe_hp (PedGeometry* geom) - case UFS_MAGIC_LFN: - case UFS_MAGIC_FEA: - case UFS_MAGIC_4GB: -- block_size = PED_BE32_TO_CPU(sb->fs_bsize) / 512; -+ block_size = PED_BE32_TO_CPU(sb->fs_bsize) / geom->dev->sector_size; - block_count = PED_BE32_TO_CPU(sb->fs_size); - return ped_geometry_new (geom->dev, geom->start, - block_size * block_count); -@@ -234,7 +235,7 @@ ufs_probe_hp (PedGeometry* geom) - case UFS_MAGIC_LFN: - case UFS_MAGIC_FEA: - case UFS_MAGIC_4GB: -- block_size = PED_LE32_TO_CPU(sb->fs_bsize) / 512; -+ block_size = PED_LE32_TO_CPU(sb->fs_bsize) / geom->dev->sector_size; - block_count = PED_LE32_TO_CPU(sb->fs_size); - return ped_geometry_new (geom->dev, geom->start, - block_size * block_count); -@@ -254,14 +255,12 @@ static PedFileSystemType ufs_type_sun = { - next: NULL, - ops: &ufs_ops_sun, - name: "sun-ufs", -- block_sizes: SUN_UFS_BLOCK_SIZES - }; - - static PedFileSystemType ufs_type_hp = { - next: NULL, - ops: &ufs_ops_hp, - name: "hp-ufs", -- block_sizes: HP_UFS_BLOCK_SIZES - }; - - void -diff --git a/libparted/fs/xfs/xfs.c b/libparted/fs/xfs/xfs.c -index 0062604..d4144f8 100644 ---- a/libparted/fs/xfs/xfs.c -+++ b/libparted/fs/xfs/xfs.c -@@ -33,39 +33,34 @@ - #include "xfs_types.h" - #include "xfs_sb.h" - --#define XFS_BLOCK_SIZES ((int[2]){512, 0}) -- - static PedGeometry* - xfs_probe (PedGeometry* geom) - { - PedSector block_size; - PedSector block_count; -- union { -- struct xfs_sb sb; -- char bytes [512]; -- } buf; -+ struct xfs_sb *sb = (struct xfs_sb *)alloca (geom->dev->sector_size); - - if (geom->length < XFS_SB_DADDR + 1) - return NULL; -- if (!ped_geometry_read (geom, &buf, XFS_SB_DADDR, 1)) -+ if (!ped_geometry_read (geom, sb, XFS_SB_DADDR, 1)) - return NULL; - -- if (PED_LE32_TO_CPU (buf.sb.sb_magicnum) == XFS_SB_MAGIC) { -- block_size = PED_LE32_TO_CPU (buf.sb.sb_blocksize) / 512; -- block_count = PED_LE64_TO_CPU (buf.sb.sb_dblocks); -+ if (PED_LE32_TO_CPU (sb->sb_magicnum) == XFS_SB_MAGIC) { -+ block_size = PED_LE32_TO_CPU (sb->sb_blocksize) / geom->dev->sector_size; -+ block_count = PED_LE64_TO_CPU (sb->sb_dblocks); - - return ped_geometry_new (geom->dev, geom->start, - block_size * block_count); - } - -- if (PED_BE32_TO_CPU (buf.sb.sb_magicnum) == XFS_SB_MAGIC) { -- block_size = PED_BE32_TO_CPU (buf.sb.sb_blocksize) / 512; -- block_count = PED_BE64_TO_CPU (buf.sb.sb_dblocks); -+ if (PED_BE32_TO_CPU (sb->sb_magicnum) == XFS_SB_MAGIC) { -+ block_size = PED_BE32_TO_CPU (sb->sb_blocksize) / geom->dev->sector_size; -+ block_count = PED_BE64_TO_CPU (sb->sb_dblocks); - -- return ped_geometry_new (geom->dev, geom->start, -+ geom = ped_geometry_new (geom->dev, geom->start, - block_size * block_count); -+ return geom; - } -- - return NULL; - } - -@@ -77,7 +72,6 @@ static PedFileSystemType xfs_type = { - next: NULL, - ops: &xfs_ops, - name: "xfs", -- block_sizes: XFS_BLOCK_SIZES - }; - - void --- -1.9.3 - diff --git a/0095-libparted-add-support-for-implicit-FBA-DASD-partitio.patch b/0095-libparted-add-support-for-implicit-FBA-DASD-partitio.patch deleted file mode 100644 index 94d810c..0000000 --- a/0095-libparted-add-support-for-implicit-FBA-DASD-partitio.patch +++ /dev/null @@ -1,197 +0,0 @@ -From f70ff1fc474764c3a71318ddb4e0d26afc52ac47 Mon Sep 17 00:00:00 2001 -From: Nageswara R Sastry -Date: Wed, 21 Aug 2013 16:09:56 -0700 -Subject: [PATCH 095/131] libparted: add support for implicit FBA DASD - partitions - -Fixed Block Access (FBA) DASDs are mainframe-specific disk devices -which are layed out as a sequence of 512-byte sectors. In contrast -to ECKD DASDs, these disks do not require formatting and resemble -the LBA layout of non-mainframe disks. Despite this resemblance, -the Linux kernel applies special handling during partition detection -for FBA DASDs, resulting in a single, immutable partition being -reported. - -While actual FBA DASD hardware is no longer available, the z/VM -hypervisor can simulate FBA DASD disks, backed by either ECKD or -SCSI devices. - -This patch adds support for recognizing FBA DASD partitions -to parted. - -Signed-off-by: Nageswara R Sastry -Signed-off-by: Peter Oberparleiter ---- - include/parted/fdasd.in.h | 2 ++ - libparted/labels/dasd.c | 63 ++++++++++++++++++++++++++++++++++++++++------- - libparted/labels/fdasd.c | 5 ++++ - 3 files changed, 61 insertions(+), 9 deletions(-) - -diff --git a/include/parted/fdasd.in.h b/include/parted/fdasd.in.h -index ac30134..a755246 100644 ---- a/include/parted/fdasd.in.h -+++ b/include/parted/fdasd.in.h -@@ -194,6 +194,8 @@ typedef struct fdasd_anchor { - volume_label_t *vlabel; - config_data_t confdata[USABLE_PARTITIONS]; - struct fdasd_hd_geometry geo; -+ unsigned int label_block; -+ unsigned int FBA_layout; - } fdasd_anchor_t; - - enum offset {lower, upper}; -diff --git a/libparted/labels/dasd.c b/libparted/labels/dasd.c -index a769866..b4e80b1 100644 ---- a/libparted/labels/dasd.c -+++ b/libparted/labels/dasd.c -@@ -71,6 +71,7 @@ typedef struct { - - typedef struct { - unsigned int format_type; -+ unsigned int label_block; - volume_label_t vlabel; - } DasdDiskSpecific; - -@@ -151,6 +152,7 @@ dasd_alloc (const PedDevice* dev) - - /* CDL format, newer */ - disk_specific->format_type = 2; -+ disk_specific->label_block = 2; - - /* Setup volume label (for fresh disks) */ - snprintf(volser, sizeof(volser), "0X%04X", arch_specific->devno); -@@ -226,7 +228,9 @@ dasd_probe (const PedDevice *dev) - - fdasd_check_api_version(&anchor, arch_specific->fd); - -- if (fdasd_check_volume(&anchor, arch_specific->fd)) -+ /* Labels are required on CDL formatted DASDs. */ -+ if (fdasd_check_volume(&anchor, arch_specific->fd) && -+ anchor.FBA_layout == 0) - goto error_cleanup; - - fdasd_cleanup(&anchor); -@@ -273,17 +277,53 @@ dasd_read (PedDisk* disk) - fdasd_initialize_anchor(&anchor); - - fdasd_get_geometry(disk->dev, &anchor, arch_specific->fd); -+ disk_specific->label_block = anchor.label_block; -+ -+ if ((anchor.geo.cylinders * anchor.geo.heads) > BIG_DISK_SIZE) -+ anchor.big_disk++; - - /* check dasd for labels and vtoc */ -- if (fdasd_check_volume(&anchor, arch_specific->fd)) -- goto error_close_dev; -+ if (fdasd_check_volume(&anchor, arch_specific->fd)) { -+ DasdPartitionData* dasd_data; -+ -+ /* Kernel partitioning code will report 'implicit' partitions -+ * for non-CDL format DASDs even when there is no -+ * label/VTOC. */ -+ if (anchor.FBA_layout == 0) -+ goto error_close_dev; -+ -+ disk_specific->format_type = 1; -+ -+ /* Register implicit partition */ -+ ped_disk_delete_all (disk); -+ -+ start = (PedSector) arch_specific->real_sector_size / -+ (PedSector) disk->dev->sector_size * -+ (PedSector) (anchor.label_block + 1); -+ end = disk->dev->length - 1; -+ part = ped_partition_new (disk, PED_PARTITION_NORMAL, NULL, -+ start, end); -+ if (!part) -+ goto error_close_dev; -+ -+ part->num = 1; -+ part->fs_type = ped_file_system_probe (&part->geom); -+ dasd_data = part->disk_specific; -+ dasd_data->raid = 0; -+ dasd_data->lvm = 0; -+ dasd_data->type = 0; -+ -+ if (!ped_disk_add_partition (disk, part, NULL)) -+ goto error_close_dev; -+ -+ fdasd_cleanup(&anchor); -+ -+ return 1; -+ } - - /* Save volume label (read by fdasd_check_volume) for writing */ - memcpy(&disk_specific->vlabel, anchor.vlabel, sizeof(volume_label_t)); - -- if ((anchor.geo.cylinders * anchor.geo.heads) > BIG_DISK_SIZE) -- anchor.big_disk++; -- - ped_disk_delete_all (disk); - - bool is_ldl = strncmp(anchor.vlabel->volkey, -@@ -348,7 +388,7 @@ dasd_read (PedDisk* disk) - / (long long) disk->dev->sector_size - * (long long) (cms_ptr->block_count - 1) - 1; - -- part = ped_partition_new (disk, PED_PARTITION_PROTECTED, NULL, start, end); -+ part = ped_partition_new (disk, PED_PARTITION_NORMAL, NULL, start, end); - if (!part) - goto error_close_dev; - -@@ -923,7 +963,12 @@ dasd_alloc_metadata (PedDisk* disk) - the start of the first partition */ - if (disk_specific->format_type == 1) { - part = ped_disk_get_partition(disk, 1); -- vtoc_end = part->geom.start - 1; -+ if (part) -+ vtoc_end = part->geom.start - 1; -+ else -+ vtoc_end = (PedSector) arch_specific->real_sector_size / -+ (PedSector) disk->dev->sector_size * -+ (PedSector) disk_specific->label_block; - } - else { - if (disk->dev->type == PED_DEVICE_FILE) -@@ -943,7 +988,7 @@ dasd_alloc_metadata (PedDisk* disk) - goto error; - } - -- if (disk_specific->format_type == 1) { -+ if (disk_specific->format_type == 1 && part) { - /* - For LDL or CMS there may be trailing metadata as well. - For example: the last block of a CMS reserved file, -diff --git a/libparted/labels/fdasd.c b/libparted/labels/fdasd.c -index e235dd3..f92065f 100644 ---- a/libparted/labels/fdasd.c -+++ b/libparted/labels/fdasd.c -@@ -721,6 +721,7 @@ fdasd_check_volume (fdasd_anchor_t *anc, int fd) - unsigned long b = -1; - char str[LINE_LENGTH]; - -+ memset(v, 0, sizeof(volume_label_t)); - vtoc_read_volume_label (fd, anc->label_pos, v); - - if (strncmp(v->vollbl, vtoc_ebcdic_enc ("VOL1", str, 4), 4) == 0) { -@@ -800,6 +801,8 @@ fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int f) - dasd_info.dev_type = 13200; - dasd_info.label_block = 2; - dasd_info.devno = 513; -+ dasd_info.label_block = 2; -+ dasd_info.FBA_layout = 0; - } else { - if (ioctl(f, HDIO_GETGEO, &anc->geo) != 0) - fdasd_error(anc, unable_to_ioctl, -@@ -820,6 +823,8 @@ fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int f) - anc->label_pos = dasd_info.label_block * blksize; - anc->devno = dasd_info.devno; - anc->fspace_trk = anc->geo.cylinders * anc->geo.heads - FIRST_USABLE_TRK; -+ anc->label_block = dasd_info.label_block; -+ anc->FBA_layout = dasd_info.FBA_layout; - } - - /* --- -1.9.3 - diff --git a/0096-libparted-add-support-for-EAV-DASD-partitions.patch b/0096-libparted-add-support-for-EAV-DASD-partitions.patch deleted file mode 100644 index 620aed5..0000000 --- a/0096-libparted-add-support-for-EAV-DASD-partitions.patch +++ /dev/null @@ -1,1071 +0,0 @@ -From cbec53fdb9c8b244b497e42b0b215a8276803a88 Mon Sep 17 00:00:00 2001 -From: Nageswara R Sastry -Date: Wed, 21 Aug 2013 16:27:13 -0700 -Subject: [PATCH 096/131] libparted: add support for EAV DASD partitions - -Extended Address Volume (EAV) DASDs are ECKD DASDs with more than -65520 cylinders. This patch adds support for recognizing and -modifying partitions on EAV DASDs to Parted. The changes are -based on the EAV support added to version 1.8.1 [1] of the -s390-tools package. - -[1] http://www.ibm.com/developerworks/linux/linux390/s390-tools-1.8.1.html - -Signed-off-by: Nageswara R Sastry -Signed-off-by: Peter Oberparleiter ---- - include/parted/fdasd.in.h | 89 +++++++++++++++--- - include/parted/vtoc.in.h | 59 ++++++++++-- - libparted/labels/dasd.c | 1 + - libparted/labels/fdasd.c | 226 ++++++++++++++++++++++++++++++++-------------- - libparted/labels/vtoc.c | 173 ++++++++++++++++++++++++++++++----- - 5 files changed, 436 insertions(+), 112 deletions(-) - -diff --git a/include/parted/fdasd.in.h b/include/parted/fdasd.in.h -index a755246..b4e7dd1 100644 ---- a/include/parted/fdasd.in.h -+++ b/include/parted/fdasd.in.h -@@ -74,6 +74,80 @@ typedef struct dasd_information_t { - char configuration_data[256]; /* from read_configuration_data */ - } dasd_information_t; - -+struct dasd_eckd_characteristics { -+ unsigned short cu_type; -+ struct { -+ unsigned char support:2; -+ unsigned char async:1; -+ unsigned char reserved:1; -+ unsigned char cache_info:1; -+ unsigned char model:3; -+ } __attribute__ ((packed)) cu_model; -+ unsigned short dev_type; -+ unsigned char dev_model; -+ struct { -+ unsigned char mult_burst:1; -+ unsigned char RT_in_LR:1; -+ unsigned char reserved1:1; -+ unsigned char RD_IN_LR:1; -+ unsigned char reserved2:4; -+ unsigned char reserved3:8; -+ unsigned char defect_wr:1; -+ unsigned char XRC_supported:1; -+ unsigned char reserved4:1; -+ unsigned char striping:1; -+ unsigned char reserved5:4; -+ unsigned char cfw:1; -+ unsigned char reserved6:2; -+ unsigned char cache:1; -+ unsigned char dual_copy:1; -+ unsigned char dfw:1; -+ unsigned char reset_alleg:1; -+ unsigned char sense_down:1; -+ } __attribute__ ((packed)) facilities; -+ unsigned char dev_class; -+ unsigned char unit_type; -+ unsigned short no_cyl; -+ unsigned short trk_per_cyl; -+ unsigned char sec_per_trk; -+ unsigned char byte_per_track[3]; -+ unsigned short home_bytes; -+ unsigned char formula; -+ union { -+ struct { -+ unsigned char f1; -+ unsigned short f2; -+ unsigned short f3; -+ } __attribute__ ((packed)) f_0x01; -+ struct { -+ unsigned char f1; -+ unsigned char f2; -+ unsigned char f3; -+ unsigned char f4; -+ unsigned char f5; -+ } __attribute__ ((packed)) f_0x02; -+ } __attribute__ ((packed)) factors; -+ unsigned short first_alt_trk; -+ unsigned short no_alt_trk; -+ unsigned short first_dia_trk; -+ unsigned short no_dia_trk; -+ unsigned short first_sup_trk; -+ unsigned short no_sup_trk; -+ unsigned char MDR_ID; -+ unsigned char OBR_ID; -+ unsigned char director; -+ unsigned char rd_trk_set; -+ unsigned short max_rec_zero; -+ unsigned char reserved1; -+ unsigned char RWANY_in_LR; -+ unsigned char factor6; -+ unsigned char factor7; -+ unsigned char factor8; -+ unsigned char reserved2[3]; -+ unsigned char reserved3[6]; -+ unsigned int long_no_cyl; -+} __attribute__ ((packed)); -+ - /* - * struct format_data_t - * represents all data necessary to format a dasd -@@ -116,18 +190,6 @@ typedef struct format_data_t { - #define BLKRRPART _IO(0x12,95) - /* get block device sector size */ - #define BLKSSZGET _IO(0x12,104) -- --/***************************************************************************** -- * SECTION: Definition from hdreq.h * -- *****************************************************************************/ -- --struct fdasd_hd_geometry { -- unsigned char heads; -- unsigned char sectors; -- unsigned short cylinders; -- unsigned long start; --}; -- - /* get device geometry */ - #define HDIO_GETGEO 0x0301 - -@@ -189,10 +251,13 @@ typedef struct fdasd_anchor { - format4_label_t *f4; - format5_label_t *f5; - format7_label_t *f7; -+ format9_label_t *f9; /* template for all f9 labels */ - partition_info_t *first; - partition_info_t *last; - volume_label_t *vlabel; - config_data_t confdata[USABLE_PARTITIONS]; -+ u_int32_t hw_cylinders; -+ u_int32_t formatted_cylinders; - struct fdasd_hd_geometry geo; - unsigned int label_block; - unsigned int FBA_layout; -diff --git a/include/parted/vtoc.in.h b/include/parted/vtoc.in.h -index d79ce39..499c2d3 100644 ---- a/include/parted/vtoc.in.h -+++ b/include/parted/vtoc.in.h -@@ -42,6 +42,18 @@ - - #define VOLSER_LENGTH 6 - #define BIG_DISK_SIZE 0x10000 -+#define LV_COMPAT_CYL 0xFFFE -+ -+/***************************************************************************** -+ * SECTION: Definition from hdreq.h * -+ *****************************************************************************/ -+ -+struct fdasd_hd_geometry { -+ unsigned char heads; -+ unsigned char sectors; -+ unsigned short cylinders; -+ unsigned long start; -+}; - - - typedef struct ttr ttr_t; -@@ -59,6 +71,7 @@ typedef struct ds5ext ds5ext_t; - typedef struct format5_label format5_label_t; - typedef struct ds7ext ds7ext_t; - typedef struct format7_label format7_label_t; -+typedef struct format9_label format9_label_t; - - struct __attribute__ ((packed)) ttr { - u_int16_t tt; -@@ -169,6 +182,10 @@ struct __attribute__ ((packed)) dev_const { - u_int8_t DS4DEVDB; /* number of directory blocks per track */ - }; - -+/* -+ * format 1 and format 8 label have the same layout so we use the following -+ * structure for both. -+ */ - struct __attribute__ ((packed)) format1_label { - char DS1DSNAM[44]; /* data set name */ - u_int8_t DS1FMTID; /* format identifier */ -@@ -229,7 +246,11 @@ struct __attribute__ ((packed)) format4_label { - char res2[10]; /* reserved */ - u_int8_t DS4EFLVL; /* extended free-space management level */ - cchhb_t DS4EFPTR; /* pointer to extended free-space info */ -- char res3[9]; /* reserved */ -+ char res3; /* reserved */ -+ u_int32_t DS4DCYL; /* number of logical cyls */ -+ char res4[2]; /* reserved */ -+ u_int8_t DS4DEVF2; /* device flags */ -+ char res5; /* reserved */ - }; - - struct __attribute__ ((packed)) ds5ext { -@@ -261,12 +282,28 @@ struct __attribute__ ((packed)) format7_label { - cchhb_t DS7PTRDS; /* pointer to next FMT7 DSCB */ - }; - -+struct __attribute__ ((packed)) format9_label { -+ u_int8_t DS9KEYID; /* key code for format 9 labels (0x09) */ -+ u_int8_t DS9SUBTY; /* subtype (0x01) */ -+ u_int8_t DS9NUMF9; /* number of F9 datasets */ -+ u_int8_t res1[41]; /* reserved */ -+ u_int8_t DS9FMTID; /* format identifier */ -+ u_int8_t res2[95]; /* reserved */ -+}; -+ - char *vtoc_ebcdic_enc (char const *source, char *target, int l); - char *vtoc_ebcdic_dec (char const *source, char *target, int l); - void vtoc_set_extent (extent_t *ext, u_int8_t typeind, u_int8_t seqno, - cchh_t *lower, cchh_t *upper); --void vtoc_set_cchh (cchh_t *addr, u_int16_t cc, u_int16_t hh); --void vtoc_set_cchhb (cchhb_t *addr, u_int16_t cc, u_int16_t hh, u_int8_t b); -+void vtoc_set_cchh (cchh_t *addr, u_int32_t cc, u_int16_t hh); -+u_int32_t vtoc_get_cyl_from_cchh(cchh_t *addr); -+u_int16_t vtoc_get_head_from_cchh(cchh_t *addr); -+void vtoc_set_cchhb (cchhb_t *addr, u_int32_t cc, u_int16_t hh, u_int8_t b); -+u_int32_t vtoc_get_cyl_from_cchhb(cchhb_t *addr); -+u_int16_t vtoc_get_head_from_cchhb(cchhb_t *addr); -+u_int64_t cchhb2blk(cchhb_t *p, struct fdasd_hd_geometry *geo); -+u_int64_t cchh2blk (cchh_t *p, struct fdasd_hd_geometry *geo); -+u_int32_t cchh2trk (cchh_t *p, struct fdasd_hd_geometry *geo); - void vtoc_set_date (labeldate_t *d, u_int8_t year, u_int16_t day); - - void vtoc_volume_label_init (volume_label_t *vlabel); -@@ -295,14 +332,16 @@ void vtoc_write_label (int fd, unsigned long position, - format1_label_t const *f1, - format4_label_t const *f4, - format5_label_t const *f5, -- format7_label_t const *f7); -+ format7_label_t const *f7, -+ format9_label_t const *f9); - - void vtoc_init_format1_label (char *volid, unsigned int blksize, - extent_t *part_extent, format1_label_t *f1); - - void vtoc_init_format4_label (format4_label_t *f4lbl, - unsigned int usable_partitions, -- unsigned int cylinders, -+ unsigned int compat_cylinders, -+ unsigned int real_cylinders, - unsigned int tracks, - unsigned int blocks, - unsigned int blksize, -@@ -329,8 +368,16 @@ void vtoc_update_format7_label_add (format7_label_t *f7, int verbose, - void vtoc_update_format7_label_del (format7_label_t *f7, int verbose, - u_int32_t a, u_int32_t b); - -+void vtoc_init_format8_label (char *volid, unsigned int blksize, -+ extent_t *part_extent, format1_label_t *f1); -+ -+void vtoc_update_format8_label (cchhb_t *associated_f9, format1_label_t *f8); -+ -+void vtoc_init_format9_label (format9_label_t *f9); -+ - void vtoc_set_freespace(format4_label_t *f4, format5_label_t *f5, - format7_label_t *f7, char ch, int verbose, -- u_int32_t start, u_int32_t stop, int cyl, int trk); -+ u_int32_t start, u_int32_t stop, u_int32_t cyl, -+ u_int32_t trk); - - #endif /* VTOC_H */ -diff --git a/libparted/labels/dasd.c b/libparted/labels/dasd.c -index b4e80b1..081b3c5 100644 ---- a/libparted/labels/dasd.c -+++ b/libparted/labels/dasd.c -@@ -631,6 +631,7 @@ dasd_write (const PedDisk* disk) - /* initialize the anchor */ - fdasd_initialize_anchor(&anchor); - fdasd_get_geometry(disk->dev, &anchor, arch_specific->fd); -+ fdasd_check_volume(&anchor, arch_specific->fd); - memcpy(anchor.vlabel, &disk_specific->vlabel, sizeof(volume_label_t)); - anchor.vlabel_changed++; - -diff --git a/libparted/labels/fdasd.c b/libparted/labels/fdasd.c -index f92065f..2735b2a 100644 ---- a/libparted/labels/fdasd.c -+++ b/libparted/labels/fdasd.c -@@ -59,6 +59,48 @@ setpos (fdasd_anchor_t *anc, int dsn, int pos) - anc->partno[dsn] = pos; - } - -+static u_int32_t -+get_usable_cylinders (fdasd_anchor_t *anc) -+{ -+ u_int32_t cyl; -+ -+ /* large volume */ -+ if (anc->f4->DS4DEVCT.DS4DSCYL == LV_COMPAT_CYL && -+ anc->f4->DS4DCYL > anc->f4->DS4DEVCT.DS4DSCYL) -+ return anc->f4->DS4DCYL; -+ /* normal volume */ -+ if (anc->f4->DS4DEVCT.DS4DEVFG & ALTERNATE_CYLINDERS_USED) -+ cyl = anc->f4->DS4DEVCT.DS4DSCYL - -+ (u_int16_t) anc->f4->DS4DEVAC; -+ else -+ cyl = anc->f4->DS4DEVCT.DS4DSCYL; -+ return cyl; -+} -+ -+static void -+get_addr_of_highest_f1_f8_label (fdasd_anchor_t *anc, cchhb_t *addr) -+{ -+ -+ u_int8_t record; -+ /* We have to count the follwing labels: -+ * one format 4 -+ * one format 5 -+ * format 7 only if we have moren then BIG_DISK_SIZE tracks -+ * one for each format 1 or format 8 label == one for each partition -+ * one for each format 9 label before the last format 8 -+ * We assume that all partitions use format 8 labels when -+ * anc->formatted_cylinders > LV_COMPAT_CYL -+ * Note: Record zero is special, so block 0 on our disk is record 1! -+ */ -+ -+ record = anc->used_partitions + 2; -+ if (anc->big_disk) -+ record++; -+ if (anc->formatted_cylinders > LV_COMPAT_CYL) -+ record += anc->used_partitions - 1; -+ vtoc_set_cchhb(addr, VTOC_START_CC, VTOC_START_HH, record); -+} -+ - void - fdasd_cleanup (fdasd_anchor_t *anchor) - { -@@ -72,6 +114,7 @@ fdasd_cleanup (fdasd_anchor_t *anchor) - free(anchor->f4); - free(anchor->f5); - free(anchor->f7); -+ free(anchor->f9); - free(anchor->vlabel); - - p = anchor->first; -@@ -82,6 +125,7 @@ fdasd_cleanup (fdasd_anchor_t *anchor) - if (p == NULL) - return; - q = p->next; -+ free(p->f1); - free(p); - p = q; - } -@@ -154,17 +198,6 @@ fdasd_error (fdasd_anchor_t *anc, enum fdasd_failure why, char const *str) - } - - /* -- * converts cyl-cyl-head-head-blk to blk -- */ --static unsigned long --cchhb2blk (cchhb_t *p, struct fdasd_hd_geometry *geo) --{ -- PDEBUG -- return (unsigned long) (p->cc * geo->heads * geo->sectors -- + p->hh * geo->sectors + p->b); --} -- --/* - * initializes the anchor structure and allocates some - * memory for the labels - */ -@@ -216,9 +249,16 @@ fdasd_initialize_anchor (fdasd_anchor_t * anc) - if (anc->f7 == NULL) - fdasd_error(anc, malloc_failed, "FMT7 DSCB."); - -+ /* template for all format 9 labels */ -+ anc->f9 = malloc(sizeof(format9_label_t)); -+ if (anc->f9 == NULL) -+ fdasd_error(anc, malloc_failed, "FMT9 DSCB."); -+ - bzero(anc->f4, sizeof(format4_label_t)); - bzero(anc->f5, sizeof(format5_label_t)); - bzero(anc->f7, sizeof(format7_label_t)); -+ bzero(anc->f9, sizeof(format9_label_t)); -+ vtoc_init_format9_label(anc->f9); - - v = malloc(sizeof(volume_label_t)); - if (v == NULL) -@@ -259,6 +299,8 @@ fdasd_initialize_anchor (fdasd_anchor_t * anc) - - q = p; - } -+ anc->hw_cylinders = 0; -+ anc->formatted_cylinders = 0; - } - - /* -@@ -269,44 +311,46 @@ fdasd_write_vtoc_labels (fdasd_anchor_t * anc, int fd) - { - PDEBUG - partition_info_t *p; -- unsigned long b; -+ unsigned long b, maxblk; - char dsno[6], s1[7], s2[45], *c1, *c2, *ch; - int i = 0, k = 0; -+ cchhb_t f9addr; -+ format1_label_t emptyf1; - - b = (cchhb2blk (&anc->vlabel->vtoc, &anc->geo) - 1) * anc->blksize; - if (b <= 0) - fdasd_error (anc, vlabel_corrupted, ""); -+ maxblk = b + anc->blksize * 9; /* f4+f5+f7+3*f8+3*f9 */ - - /* write FMT4 DSCB */ -- vtoc_write_label (fd, b, NULL, anc->f4, NULL, NULL); -+ vtoc_write_label (fd, b, NULL, anc->f4, NULL, NULL, NULL); -+ b += anc->blksize; - - /* write FMT5 DSCB */ -+ vtoc_write_label (fd, b, NULL, NULL, anc->f5, NULL, NULL); - b += anc->blksize; -- vtoc_write_label (fd, b, NULL, NULL, anc->f5, NULL); - - /* write FMT7 DSCB */ - if (anc->big_disk) { -+ vtoc_write_label (fd, b, NULL, NULL, NULL, anc->f7, NULL); - b += anc->blksize; -- vtoc_write_label (fd, b, NULL, NULL, NULL, anc->f7); - } - -- /* loop over all FMT1 DSCBs */ -- p = anc->first; -- for (i = 0; i < USABLE_PARTITIONS; i++) { -- b += anc->blksize; -+ /* loop over all partitions (format 1 or format 8 DCB) */ -+ for (p = anc->first; p != NULL; p = p->next) { - - if (p->used != 0x01) { -- vtoc_write_label (fd, b, p->f1, NULL, NULL, NULL); - continue; - } - -+ i++; - strncpy (p->f1->DS1DSSN, anc->vlabel->volid, 6); - - ch = p->f1->DS1DSNAM; - vtoc_ebcdic_dec (ch, ch, 44); - c1 = ch + 7; - -- if (getdsn (anc, i) > -1) { -+ if (getdsn (anc, i-1) > -1) { - /* re-use the existing data set name */ - c2 = strchr (c1, '.'); - if (c2 != NULL) -@@ -325,11 +369,7 @@ fdasd_write_vtoc_labels (fdasd_anchor_t * anc, int fd) - while (getpos (anc, k) > -1) - k++; - -- setpos (anc, k, i); -- -- strncpy (s2, ch, 44); -- s2[44] = 0; -- vtoc_ebcdic_dec (s2, s2, 44); -+ setpos (anc, k, i-1); - - strncpy (ch, "LINUX.V " " ", 44); - -@@ -366,8 +406,32 @@ fdasd_write_vtoc_labels (fdasd_anchor_t * anc, int fd) - - vtoc_ebcdic_enc (ch, ch, 44); - -- vtoc_write_label (fd, b, p->f1, NULL, NULL, NULL); -- p = p->next; -+ if (p->f1->DS1FMTID == 0xf8 ) { -+ /* Now as we know where which label will be written, we -+ * can add the address of the format 9 label to the -+ * format 8 label. The f9 record will be written to the -+ * block after the current blk. Remember: records are of -+ * by one, so we have to add 2 and not just one. -+ */ -+ vtoc_set_cchhb(&f9addr, VTOC_START_CC, VTOC_START_HH, -+ ((b / anc->blksize) % anc->geo.sectors) + 2); -+ vtoc_update_format8_label(&f9addr, p->f1); -+ vtoc_write_label(fd, b, p->f1, NULL, NULL, NULL, NULL); -+ b += anc->blksize; -+ vtoc_write_label(fd, b, NULL, NULL, NULL, NULL, -+ anc->f9); -+ b += anc->blksize; -+ } else { -+ vtoc_write_label(fd, b, p->f1, NULL, NULL, NULL, NULL); -+ b += anc->blksize; -+ } -+ } -+ -+ /* write empty labels to the rest of the blocks */ -+ bzero(&emptyf1, sizeof(emptyf1)); -+ while (b < maxblk) { -+ vtoc_write_label(fd, b, &emptyf1, NULL, NULL, NULL, NULL); -+ b += anc->blksize; - } - } - -@@ -394,20 +458,25 @@ int - fdasd_prepare_labels (fdasd_anchor_t *anc, int fd) - { - PDEBUG -- partition_info_t *p = anc->first; -+ partition_info_t *p; - char dsno[6], s1[7], s2[45], *c1, *c2, *ch; - int i = 0, k = 0; - -- /* loop over all FMT1 DSCBs */ -- p = anc->first; -- for (i = 0; i < USABLE_PARTITIONS; i++) { -+ /* loop over all partitions (format 1 or format 8 DCB) */ -+ for (p = anc->first; p != NULL; p = p->next) { -+ -+ if (p->used != 0x01) { -+ continue; -+ } -+ -+ i++; - strncpy (p->f1->DS1DSSN, anc->vlabel->volid, 6); - - ch = p->f1->DS1DSNAM; - vtoc_ebcdic_dec (ch, ch, 44); - c1 = ch + 7; - -- if (getdsn (anc, i) > -1) { -+ if (getdsn (anc, i-1) > -1) { - /* re-use the existing data set name */ - c2 = strchr (c1, '.'); - if (c2 != NULL) -@@ -426,11 +495,7 @@ fdasd_prepare_labels (fdasd_anchor_t *anc, int fd) - while (getpos (anc, k) > -1) - k++; - -- setpos (anc, k, i); -- -- strncpy (s2, ch, 44); -- s2[44] = 0; -- vtoc_ebcdic_dec (s2, s2, 44); -+ setpos (anc, k, i-1); - - strncpy (ch, "LINUX.V " " ", 44); - -@@ -466,7 +531,6 @@ fdasd_prepare_labels (fdasd_anchor_t *anc, int fd) - } - - vtoc_ebcdic_enc (ch, ch, 44); -- p = p->next; - } - - return 1; -@@ -482,6 +546,7 @@ fdasd_recreate_vtoc (fdasd_anchor_t *anc) - vtoc_init_format4_label(anc->f4, - USABLE_PARTITIONS, - anc->geo.cylinders, -+ anc->formatted_cylinders, - anc->geo.heads, - anc->geo.sectors, - anc->blksize, -@@ -492,8 +557,8 @@ fdasd_recreate_vtoc (fdasd_anchor_t *anc) - vtoc_set_freespace(anc->f4, anc->f5, anc->f7, - '+', anc->verbose, - FIRST_USABLE_TRK, -- anc->geo.cylinders * anc->geo.heads - 1, -- anc->geo.cylinders, anc->geo.heads); -+ anc->formatted_cylinders * anc->geo.heads - 1, -+ anc->formatted_cylinders, anc->geo.heads); - - for (i = 0; i < USABLE_PARTITIONS; i++) { - bzero(p->f1, sizeof(format1_label_t)); -@@ -507,7 +572,8 @@ fdasd_recreate_vtoc (fdasd_anchor_t *anc) - } - - anc->used_partitions = 0; -- anc->fspace_trk = anc->geo.cylinders * anc->geo.heads - FIRST_USABLE_TRK; -+ anc->fspace_trk = anc->formatted_cylinders * anc->geo.heads - -+ FIRST_USABLE_TRK; - - for (i=0; ifirst; -- unsigned int h = anc->geo.heads; -- unsigned long max = anc->geo.cylinders * h - 1; -+ unsigned long max = anc->formatted_cylinders * anc->geo.heads - 1; - int i; - char *ch; - - anc->used_partitions = anc->geo.sectors - 2 - anc->f4->DS4DSREC; - - for (i = 1; i <= USABLE_PARTITIONS; i++) { -- if (p->f1->DS1FMTID != 0xf1) { -+ if (p->f1->DS1FMTID != 0xf1 && -+ p->f1->DS1FMTID != 0xf8) { - if (i == 1) - /* there is no partition at all */ - anc->fspace_trk = max - FIRST_USABLE_TRK + 1; -@@ -546,8 +612,8 @@ fdasd_update_partition_info (fdasd_anchor_t *anc) - - /* this is a valid format 1 label */ - p->used = 0x01; -- p->start_trk = p->f1->DS1EXT1.llimit.cc * h + p->f1->DS1EXT1.llimit.hh; -- p->end_trk = p->f1->DS1EXT1.ulimit.cc * h + p->f1->DS1EXT1.ulimit.hh; -+ p->start_trk = cchh2trk(&p->f1->DS1EXT1.llimit, &anc->geo); -+ p->end_trk = cchh2trk(&p->f1->DS1EXT1.ulimit, &anc->geo); - p->len_trk = p->end_trk - p->start_trk + 1; - - if (i == 1) { -@@ -618,14 +684,22 @@ fdasd_process_valid_vtoc (fdasd_anchor_t * anc, unsigned long b, int fd) - format1_label_t q; - char s[5], *ch; - -+ if (anc->f4->DS4DEVCT.DS4DSCYL == LV_COMPAT_CYL && -+ anc->f4->DS4DCYL > anc->f4->DS4DEVCT.DS4DSCYL) -+ anc->formatted_cylinders = anc->f4->DS4DCYL; -+ else -+ anc->formatted_cylinders = anc->f4->DS4DEVCT.DS4DSCYL; -+ anc->fspace_trk = anc->formatted_cylinders * anc->geo.heads - -+ FIRST_USABLE_TRK; - b += anc->blksize; - -- for (i = 1; i <= anc->geo.sectors; i++) { -+ for (i = 1; i < anc->geo.sectors; i++) { - bzero (&q, f1size); - vtoc_read_label (fd, b, &q, NULL, NULL, NULL); - - switch (q.DS1FMTID) { - case 0xf1: -+ case 0xf8: - if (p == NULL) - break; - memcpy (p->f1, &q, f1size); -@@ -669,6 +743,12 @@ fdasd_process_valid_vtoc (fdasd_anchor_t * anc, unsigned long b, int fd) - memcpy (anc->f7, &q, f1size); - f7_counter++; - break; -+ case 0xf9: -+ /* each format 8 lable has an associated -+ * format 9 lable, but they are of no further -+ * use to us. -+ */ -+ break; - } - - b += anc->blksize; -@@ -718,7 +798,7 @@ fdasd_check_volume (fdasd_anchor_t *anc, int fd) - { - PDEBUG - volume_label_t *v = anc->vlabel; -- unsigned long b = -1; -+ long long b = -1; - char str[LINE_LENGTH]; - - memset(v, 0, sizeof(volume_label_t)); -@@ -784,6 +864,7 @@ fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int f) - PDEBUG - int blksize = 0; - dasd_information_t dasd_info; -+ struct dasd_eckd_characteristics *characteristics; - - /* We can't get geometry from a regular file, - so simulate something usable, for the sake of testing. */ -@@ -803,6 +884,8 @@ fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int f) - dasd_info.devno = 513; - dasd_info.label_block = 2; - dasd_info.FBA_layout = 0; -+ anc->hw_cylinders = ((st.st_size / blksize) / anc->geo.sectors) / -+ anc->geo.heads; - } else { - if (ioctl(f, HDIO_GETGEO, &anc->geo) != 0) - fdasd_error(anc, unable_to_ioctl, -@@ -816,13 +899,20 @@ fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int f) - if (ioctl(f, BIODASDINFO, &dasd_info) != 0) - fdasd_error(anc, unable_to_ioctl, - _("Could not retrieve disk information.")); -+ -+ characteristics = (struct dasd_eckd_characteristics *) -+ &dasd_info.characteristics; -+ if (characteristics->no_cyl == LV_COMPAT_CYL && -+ characteristics->long_no_cyl) -+ anc->hw_cylinders = characteristics->long_no_cyl; -+ else -+ anc->hw_cylinders = characteristics->no_cyl; - } - - anc->dev_type = dasd_info.dev_type; - anc->blksize = blksize; - anc->label_pos = dasd_info.label_block * blksize; - anc->devno = dasd_info.devno; -- anc->fspace_trk = anc->geo.cylinders * anc->geo.heads - FIRST_USABLE_TRK; - anc->label_block = dasd_info.label_block; - anc->FBA_layout = dasd_info.FBA_layout; - } -@@ -850,20 +940,17 @@ fdasd_get_partition_data (fdasd_anchor_t *anc, extent_t *part_extent, - unsigned int *stop_ptr) - { - PDEBUG -- unsigned int limit, cc, hh; -+ unsigned int limit; -+ u_int32_t cc, c; -+ u_int16_t hh, h; - cchh_t llimit, ulimit; - partition_info_t *q; - u_int8_t b1, b2; -- u_int16_t c, h; - unsigned int start = *start_ptr, stop = *stop_ptr; - int i; - char *ch; - -- if (anc->f4->DS4DEVCT.DS4DEVFG & ALTERNATE_CYLINDERS_USED) -- c = anc->f4->DS4DEVCT.DS4DSCYL - (u_int16_t) anc->f4->DS4DEVAC; -- else -- c = anc->f4->DS4DEVCT.DS4DSCYL; -- -+ c = get_usable_cylinders(anc); - h = anc->f4->DS4DEVCT.DS4DSTRK; - limit = (h * c - 1); - -@@ -1019,7 +1106,6 @@ fdasd_add_partition (fdasd_anchor_t *anc, unsigned int start, - cchhb_t hf1; - partition_info_t *p; - extent_t ext; -- int i; - - PDEBUG; - -@@ -1032,8 +1118,14 @@ fdasd_add_partition (fdasd_anchor_t *anc, unsigned int start, - if (fdasd_get_partition_data(anc, &ext, p, &start, &stop) != 0) - return 0; - -- PDEBUG; -- vtoc_init_format1_label(anc->vlabel->volid, anc->blksize, &ext, p->f1); -+ if (anc->formatted_cylinders > LV_COMPAT_CYL) { -+ vtoc_init_format8_label(anc->vlabel->volid, anc->blksize, &ext, -+ p->f1); -+ } else { -+ PDEBUG; -+ vtoc_init_format1_label(anc->vlabel->volid, anc->blksize, &ext, -+ p->f1); -+ } - - PDEBUG; - fdasd_enqueue_new_partition(anc); -@@ -1041,23 +1133,17 @@ fdasd_add_partition (fdasd_anchor_t *anc, unsigned int start, - PDEBUG; - anc->used_partitions += 1; - -- i = anc->used_partitions + 2; -- if (anc->big_disk) -- i++; -- PDEBUG; -- -- vtoc_set_cchhb(&hf1, VTOC_START_CC, VTOC_START_HH, i); -- -+ get_addr_of_highest_f1_f8_label(anc, &hf1); - vtoc_update_format4_label(anc->f4, &hf1, anc->f4->DS4DSREC - 1); - - PDEBUG; - -- start = ext.llimit.cc * anc->geo.heads + ext.llimit.hh; -- stop = ext.ulimit.cc * anc->geo.heads + ext.ulimit.hh; -+ start = cchh2trk(&ext.llimit, &anc->geo); -+ stop = cchh2trk(&ext.ulimit, &anc->geo); - - PDEBUG; - vtoc_set_freespace(anc->f4, anc->f5, anc->f7, '-', anc->verbose, -- start, stop, anc->geo.cylinders, anc->geo.heads); -+ start, stop, anc->formatted_cylinders, anc->geo.heads); - - anc->vtoc_changed++; - -diff --git a/libparted/labels/vtoc.c b/libparted/labels/vtoc.c -index cf2990e..fdfa94f 100644 ---- a/libparted/labels/vtoc.c -+++ b/libparted/labels/vtoc.c -@@ -218,11 +218,32 @@ vtoc_set_extent (extent_t *ext, u_int8_t typeind, u_int8_t seqno, - } - - void --vtoc_set_cchh (cchh_t *addr, u_int16_t cc, u_int16_t hh) -+vtoc_set_cchh (cchh_t *addr, u_int32_t cc, u_int16_t hh) - { - PDEBUG -- addr->cc = cc; -- addr->hh = hh; -+ addr->cc = (u_int16_t) cc; -+ addr->hh = cc >> 16; -+ addr->hh <<= 4; -+ addr->hh |= hh; -+} -+ -+u_int32_t -+vtoc_get_cyl_from_cchh (cchh_t *addr) -+{ -+ u_int32_t cyl; -+ -+ /*decode cylinder for large volumes */ -+ cyl = addr->hh & 0xFFF0; -+ cyl <<= 12; -+ cyl |= addr->cc; -+ return cyl; -+} -+ -+u_int16_t -+vtoc_get_head_from_cchh (cchh_t *addr) -+{ -+ /* decode heads for large volumes */ -+ return addr->hh & 0x000F; - } - - static void -@@ -234,12 +255,63 @@ vtoc_set_ttr (ttr_t *addr, u_int16_t tt, u_int8_t r) - } - - void --vtoc_set_cchhb (cchhb_t *addr, u_int16_t cc, u_int16_t hh, u_int8_t b) -+vtoc_set_cchhb (cchhb_t *addr, u_int32_t cc, u_int16_t hh, u_int8_t b) - { - PDEBUG -- addr->cc = cc; -- addr->hh = hh; -- addr->b = b; -+ addr->cc = (u_int16_t) cc; -+ addr->hh = cc >> 16; -+ addr->hh <<= 4; -+ addr->hh |= hh; -+ addr->b = b; -+} -+ -+u_int32_t -+vtoc_get_cyl_from_cchhb(cchhb_t *addr) -+{ -+ u_int32_t cyl; -+ -+ /* decode cylinder for large volumes */ -+ cyl = addr->hh & 0xFFF0; -+ cyl <<= 12; -+ cyl |= addr->cc; -+ return cyl; -+} -+ -+u_int16_t -+vtoc_get_head_from_cchhb(cchhb_t *addr) -+{ -+ /* decode heads for large volumes */ -+ return addr->hh & 0x000F; -+} -+ -+/* -+ * some functions to convert cyl-cyl-head-head addresses to -+ * block or track numbers -+ * Note: Record zero is special, so first block on a track is -+ * in record 1! -+ */ -+u_int64_t -+cchhb2blk (cchhb_t *p, struct fdasd_hd_geometry *geo) -+{ -+ return (u_int64_t) vtoc_get_cyl_from_cchhb(p) * -+ geo->heads * geo->sectors + -+ vtoc_get_head_from_cchhb(p) * geo->sectors + -+ p->b; -+} -+ -+u_int64_t -+cchh2blk (cchh_t *p, struct fdasd_hd_geometry *geo) -+{ -+ return (u_int64_t) vtoc_get_cyl_from_cchh(p) * -+ geo->heads * geo->sectors + -+ vtoc_get_head_from_cchh(p) * geo->sectors; -+} -+ -+u_int32_t -+cchh2trk (cchh_t *p, struct fdasd_hd_geometry *geo) -+{ -+ return vtoc_get_cyl_from_cchh(p) * geo->heads + -+ vtoc_get_head_from_cchh(p); - } - - void -@@ -506,7 +578,8 @@ vtoc_write_label (int f, unsigned long position, - format1_label_t const *f1, - format4_label_t const *f4, - format5_label_t const *f5, -- format7_label_t const *f7) -+ format7_label_t const *f7, -+ format9_label_t const *f9) - { - PDEBUG - int t; -@@ -542,6 +615,17 @@ vtoc_write_label (int f, unsigned long position, - vtoc_error(unable_to_write, "vtoc_write_label", - _("Could not write VTOC FMT7 DSCB.")); - } -+ -+ if (f9 != NULL) -+ { -+ t = sizeof(format9_label_t); -+ if (write(f, f9, t) != t) -+ { -+ close(f); -+ vtoc_error(unable_to_write, "vtoc_write_label", -+ _("Could not write VTOC FMT9 DSCB.")); -+ } -+ } - } - - /* -@@ -549,7 +633,8 @@ vtoc_write_label (int f, unsigned long position, - */ - void - vtoc_init_format4_label (format4_label_t *f4, unsigned int usable_partitions, -- unsigned int cylinders, unsigned int tracks, -+ unsigned int compat_cylinders, -+ unsigned int real_cylinders, unsigned int tracks, - unsigned int blocks, unsigned int blksize, - u_int16_t dev_type) - { -@@ -574,7 +659,7 @@ vtoc_init_format4_label (format4_label_t *f4, unsigned int usable_partitions, - f4->DS4DEVAC = 0x00; - - /* -- begin f4->DS4DEVCT -- */ -- f4->DS4DEVCT.DS4DSCYL = cylinders; -+ f4->DS4DEVCT.DS4DSCYL = compat_cylinders; - f4->DS4DEVCT.DS4DSTRK = tracks; - - switch (dev_type) { -@@ -613,7 +698,11 @@ vtoc_init_format4_label (format4_label_t *f4, unsigned int usable_partitions, - bzero(f4->res2, sizeof(f4->res2)); - f4->DS4EFLVL = 0x00; - bzero(&f4->DS4EFPTR, sizeof(f4->DS4EFPTR)); -- bzero(f4->res3, sizeof(f4->res3)); -+ bzero(&f4->res3, sizeof(f4->res3)); -+ f4->DS4DCYL = real_cylinders; -+ bzero(f4->res4, sizeof(f4->res4)); -+ f4->DS4DEVF2 = 0x40; /* allow format 8 and 9 labels */ -+ bzero(&f4->res5, sizeof(f4->res5)); - } - - /* -@@ -647,11 +736,12 @@ vtoc_init_format7_label (format7_label_t *f7) - } - - /* -- * initializes a format1 label -+ * helper function that initializes a most parts of a -+ * format1 or format 8 label, all but the field DS1FMTID - */ - void --vtoc_init_format1_label (char *volid, unsigned int blksize, -- extent_t *part_extent, format1_label_t *f1) -+vtoc_init_format_1_8_label (char *volid, unsigned int blksize, -+ extent_t *part_extent, format1_label_t *f1) - { - PDEBUG - struct tm * creatime; -@@ -666,7 +756,6 @@ vtoc_init_format1_label (char *volid, unsigned int blksize, - sprintf(str, "PART .NEW "); - vtoc_ebcdic_enc(str, str, 44); - strncpy(f1->DS1DSNAM, str, 44); -- f1->DS1FMTID = 0xf1; - strncpy(f1->DS1DSSN, " ", 6); - f1->DS1VOLSQ = 0x0001; - -@@ -704,6 +793,37 @@ vtoc_init_format1_label (char *volid, unsigned int blksize, - vtoc_set_cchhb(&f1->DS1PTRDS, 0x0000, 0x0000, 0x00); - } - -+void -+vtoc_init_format1_label (char *volid, unsigned int blksize, -+ extent_t *part_extent, format1_label_t *f1) -+{ -+ vtoc_init_format_1_8_label(volid, blksize, part_extent, f1); -+ f1->DS1FMTID = 0xf1; -+} -+ -+void -+vtoc_init_format8_label (char *volid, unsigned int blksize, -+ extent_t *part_extent, format1_label_t *f8) -+{ -+ vtoc_init_format_1_8_label(volid, blksize, part_extent, f8); -+ f8->DS1FMTID = 0xf8; -+} -+ -+void -+vtoc_update_format8_label (cchhb_t *associated_f9, format1_label_t *f8) -+{ -+ memcpy(&f8->DS1PTRDS, associated_f9, sizeof(*associated_f9)); -+} -+ -+void -+vtoc_init_format9_label (format9_label_t *f9) -+{ -+ f9->DS9KEYID = 0x09; -+ f9->DS9SUBTY = 0x01; -+ f9->DS9NUMF9 = 1; -+ f9->DS9FMTID = 0xf9; -+} -+ - /* - * do some updates to the VTOC format4 label - */ -@@ -1060,7 +1180,7 @@ vtoc_update_format7_label_add (format7_label_t *f7, int verbose, - if ((ext->a + ext->b) == 0x00000000) - continue; - -- if ((ext->b + 1) == tmp->a) { -+ if (ext->b == tmp->a) { - /* this extent precedes the new one */ - ext->b = tmp->b; - bzero(tmp, sizeof(ds7ext_t)); -@@ -1074,7 +1194,7 @@ vtoc_update_format7_label_add (format7_label_t *f7, int verbose, - continue; - } - -- if (ext->a == (tmp->b + 1)) { -+ if (ext->a == tmp->b) { - /* this extent succeeds the new one */ - ext->a = tmp->a; - bzero(tmp, sizeof(ds7ext_t)); -@@ -1119,7 +1239,7 @@ vtoc_update_format7_label_del (format7_label_t *f7, int verbose, - - if ((a == ext->a) && (b < ext->b)) { - /* left-bounded in free space gap */ -- ext->a = b + 1; -+ ext->a = b; - - if (verbose) - puts ("FMT7 add extent: left-bounded"); -@@ -1130,7 +1250,7 @@ vtoc_update_format7_label_del (format7_label_t *f7, int verbose, - - if ((a > ext->a) && (b == ext->b)) { - /* right-bounded in free space gap */ -- ext->b = a - 1; -+ ext->b = a; - - if (verbose) - puts ("FMT7 add extent: right-bounded"); -@@ -1141,8 +1261,8 @@ vtoc_update_format7_label_del (format7_label_t *f7, int verbose, - - if ((a > ext->a) && (b < ext->b)) { - /* partition devides free space into 2 pieces */ -- vtoc_update_format7_label_add(f7, verbose, b+1, ext->b); -- ext->b = a - 1; -+ vtoc_update_format7_label_add(f7, verbose, b, ext->b); -+ ext->b = a; - - if (verbose) - puts ("FMT7 add extent: 2 pieces"); -@@ -1172,14 +1292,19 @@ vtoc_update_format7_label_del (format7_label_t *f7, int verbose, - void - vtoc_set_freespace(format4_label_t *f4, format5_label_t *f5, - format7_label_t *f7, char ch, int verbose, -- u_int32_t start, u_int32_t stop, int cyl, int trk) -+ u_int32_t start, u_int32_t stop, u_int32_t cyl, -+ u_int32_t trk) - { - PDEBUG - if ((cyl * trk) > BIG_DISK_SIZE) { - if (ch == '+') -- vtoc_update_format7_label_add(f7, verbose, start, stop); -+ vtoc_update_format7_label_add(f7, verbose, start, -+ /* ds7ext RTA + 1 */ -+ stop + 1); - else if (ch == '-') -- vtoc_update_format7_label_del(f7, verbose, start, stop); -+ vtoc_update_format7_label_del(f7, verbose, start, -+ /* ds7ext RTA + 1 */ -+ stop + 1); - else - puts ("BUG: syntax error in vtoc_set_freespace call"); - --- -1.9.3 - diff --git a/0097-libparted-mklabel-to-support-EAV-DASD.patch b/0097-libparted-mklabel-to-support-EAV-DASD.patch deleted file mode 100644 index 3a5bfa1..0000000 --- a/0097-libparted-mklabel-to-support-EAV-DASD.patch +++ /dev/null @@ -1,159 +0,0 @@ -From 95649fc7d025a68074c8a00581bd24d2bd7751bc Mon Sep 17 00:00:00 2001 -From: Nageswara R Sastry -Date: Wed, 21 Aug 2013 16:36:08 -0700 -Subject: [PATCH 097/131] libparted: mklabel to support EAV DASD - -Extended Address Volume (EAV) DASDs are ECKD DASDs with more than -65520 cylinders. This patch adds support for mklabel to properly -handle unformatted EAV DASDs. - -Signed-off-by: Nageswara R Sastry ---- - include/parted/fdasd.in.h | 1 - - libparted/labels/fdasd.c | 92 +++++++++++++++++++++++++++++++++++++++++++++-- - 2 files changed, 90 insertions(+), 3 deletions(-) - -diff --git a/include/parted/fdasd.in.h b/include/parted/fdasd.in.h -index b4e7dd1..3692596 100644 ---- a/include/parted/fdasd.in.h -+++ b/include/parted/fdasd.in.h -@@ -288,7 +288,6 @@ void fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int fd); - void fdasd_check_api_version (fdasd_anchor_t *anc, int fd); - int fdasd_check_volume (fdasd_anchor_t *anc, int fd); - int fdasd_write_labels (fdasd_anchor_t *anc, int fd); --int fdasd_invalid_vtoc_pointer(fdasd_anchor_t *anc); - void fdasd_recreate_vtoc(fdasd_anchor_t *anc); - partition_info_t * fdasd_add_partition (fdasd_anchor_t *anc, - unsigned int start, unsigned int stop); -diff --git a/libparted/labels/fdasd.c b/libparted/labels/fdasd.c -index 2735b2a..b58b2be 100644 ---- a/libparted/labels/fdasd.c -+++ b/libparted/labels/fdasd.c -@@ -581,6 +581,22 @@ fdasd_recreate_vtoc (fdasd_anchor_t *anc) - anc->vtoc_changed++; - } - -+ /* -+ * initialize the VOL1 volume label -+ */ -+static void -+fdasd_init_volume_label(fdasd_anchor_t *anc, int fd) -+{ -+ volume_label_t *vlabel = anc->vlabel; -+ -+ vtoc_volume_label_init(vlabel); -+ vtoc_volume_label_set_key(vlabel, "VOL1"); -+ vtoc_volume_label_set_label(vlabel, "VOL1"); -+ -+ vtoc_set_cchhb(&vlabel->vtoc, VTOC_START_CC, VTOC_START_HH, 0x01); -+} -+ -+ - /* - * sets some important partition data - * (like used, start_trk, end_trk, len_trk) -@@ -769,6 +785,52 @@ fdasd_process_valid_vtoc (fdasd_anchor_t * anc, unsigned long b, int fd) - fdasd_update_partition_info (anc); - } - -+static void -+fdasd_invalid_vtoc_pointer(fdasd_anchor_t *anc) -+{ -+ PDEBUG -+ anc->formatted_cylinders = anc->hw_cylinders; -+ anc->fspace_trk = anc->formatted_cylinders * anc->geo.heads -+ - FIRST_USABLE_TRK; -+ vtoc_init_format4_label(anc->f4, USABLE_PARTITIONS, -+ anc->geo.cylinders, anc->formatted_cylinders, -+ anc->geo.heads, anc->geo.sectors, -+ anc->blksize, anc->dev_type); -+ -+ vtoc_init_format5_label(anc->f5); -+ vtoc_init_format7_label(anc->f7); -+ -+ vtoc_set_freespace(anc->f4, anc->f5, anc->f7, '+', anc->verbose, -+ FIRST_USABLE_TRK, -+ anc->formatted_cylinders * anc->geo.heads - 1, -+ anc->formatted_cylinders, anc->geo.heads); -+ -+ vtoc_set_cchhb(&anc->vlabel->vtoc, VTOC_START_CC, VTOC_START_HH, 0x01); -+} -+ -+/* -+ * we have a invalid FMT4 DSCB and therefore we will re-create the VTOC -+ */ -+static void -+fdasd_process_invalid_vtoc(fdasd_anchor_t *anc) -+{ -+ anc->formatted_cylinders = anc->hw_cylinders; -+ anc->fspace_trk = anc->formatted_cylinders * anc->geo.heads -+ - FIRST_USABLE_TRK; -+ vtoc_init_format4_label(anc->f4, USABLE_PARTITIONS, -+ anc->geo.cylinders, anc->formatted_cylinders, -+ anc->geo.heads, anc->geo.sectors, -+ anc->blksize, anc->dev_type); -+ -+ vtoc_init_format5_label(anc->f5); -+ vtoc_init_format7_label(anc->f7); -+ vtoc_set_freespace(anc->f4, anc->f5, anc->f7, '+', anc->verbose, -+ FIRST_USABLE_TRK, -+ anc->formatted_cylinders * anc->geo.heads - 1, -+ anc->formatted_cylinders, anc->geo.heads); -+} -+ -+ - static int - fdasd_valid_vtoc_pointer(fdasd_anchor_t *anc, unsigned long b, int fd) - { -@@ -781,6 +843,8 @@ fdasd_valid_vtoc_pointer(fdasd_anchor_t *anc, unsigned long b, int fd) - if (anc->f4->DS4IDFMT == 0xf4) { - fdasd_process_valid_vtoc (anc, b, fd); - return 0; -+ } else { -+ fdasd_process_invalid_vtoc(anc); - } - if (strncmp(anc->vlabel->volkey, vtoc_ebcdic_enc("LNX1",str,4),4) == 0 || - strncmp(anc->vlabel->volkey, vtoc_ebcdic_enc("CMS1",str,4),4) == 0) -@@ -817,13 +881,37 @@ fdasd_check_volume (fdasd_anchor_t *anc, int fd) - else - return 0; - } else { -- return 1; -+ fdasd_invalid_vtoc_pointer(anc); - } - } else if (strncmp (v->volkey, vtoc_ebcdic_enc ("LNX1", str, 4), 4) == 0 || - strncmp (v->volkey, vtoc_ebcdic_enc ("CMS1", str, 4), 4) == 0) { - return 0; -- } -+ } else if (anc->FBA_layout == 1) { -+ /* Some times LDL formatted disks does not -+ contain any volume label */ -+ return 1; -+ } else { -+ /* didn't find VOL1 volume label */ -+ anc->formatted_cylinders = anc->hw_cylinders; -+ anc->fspace_trk = anc->formatted_cylinders * anc->geo.heads -+ - FIRST_USABLE_TRK; -+ -+ fdasd_init_volume_label(anc, fd); - -+ vtoc_init_format4_label(anc->f4, USABLE_PARTITIONS, -+ anc->geo.cylinders, anc->formatted_cylinders, -+ anc->geo.heads, anc->geo.sectors, -+ anc->blksize, anc->dev_type); -+ -+ vtoc_init_format5_label(anc->f5); -+ vtoc_init_format7_label(anc->f7); -+ -+ vtoc_set_freespace(anc->f4, anc->f5, anc->f7, '+', -+ anc->verbose, FIRST_USABLE_TRK, -+ anc->formatted_cylinders * anc->geo.heads - 1, -+ anc->formatted_cylinders, anc->geo.heads); -+ return 0; -+ } - return 1; - } - --- -1.9.3 - diff --git a/0098-libparted-Avoid-dasd-as-default-disk-type-while-prob.patch b/0098-libparted-Avoid-dasd-as-default-disk-type-while-prob.patch deleted file mode 100644 index ab10637..0000000 --- a/0098-libparted-Avoid-dasd-as-default-disk-type-while-prob.patch +++ /dev/null @@ -1,68 +0,0 @@ -From 0673dabee6f5b19317b0d85e399e9f876a2c2ea7 Mon Sep 17 00:00:00 2001 -From: Nageswara R Sastry -Date: Wed, 21 Aug 2013 16:37:17 -0700 -Subject: [PATCH 098/131] libparted: Avoid dasd as default disk type while - probe - -This patch avoids setting 'dasd' as a default disk type for -'disk image file' at the time of probe. - -Signed-off-by: Nageswara R Sastry ---- - include/parted/fdasd.in.h | 1 + - libparted/labels/fdasd.c | 6 +++++- - 2 files changed, 6 insertions(+), 1 deletion(-) - -diff --git a/include/parted/fdasd.in.h b/include/parted/fdasd.in.h -index 3692596..6f6a7e0 100644 ---- a/include/parted/fdasd.in.h -+++ b/include/parted/fdasd.in.h -@@ -261,6 +261,7 @@ typedef struct fdasd_anchor { - struct fdasd_hd_geometry geo; - unsigned int label_block; - unsigned int FBA_layout; -+ bool is_file; - } fdasd_anchor_t; - - enum offset {lower, upper}; -diff --git a/libparted/labels/fdasd.c b/libparted/labels/fdasd.c -index b58b2be..7de5f34 100644 ---- a/libparted/labels/fdasd.c -+++ b/libparted/labels/fdasd.c -@@ -301,6 +301,7 @@ fdasd_initialize_anchor (fdasd_anchor_t * anc) - } - anc->hw_cylinders = 0; - anc->formatted_cylinders = 0; -+ anc->is_file = 0; - } - - /* -@@ -890,7 +891,7 @@ fdasd_check_volume (fdasd_anchor_t *anc, int fd) - /* Some times LDL formatted disks does not - contain any volume label */ - return 1; -- } else { -+ } else if (! anc->is_file) { - /* didn't find VOL1 volume label */ - anc->formatted_cylinders = anc->hw_cylinders; - anc->fspace_trk = anc->formatted_cylinders * anc->geo.heads -@@ -974,6 +975,7 @@ fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int f) - dasd_info.FBA_layout = 0; - anc->hw_cylinders = ((st.st_size / blksize) / anc->geo.sectors) / - anc->geo.heads; -+ anc->is_file = 1; - } else { - if (ioctl(f, HDIO_GETGEO, &anc->geo) != 0) - fdasd_error(anc, unable_to_ioctl, -@@ -995,6 +997,8 @@ fdasd_get_geometry (const PedDevice *dev, fdasd_anchor_t *anc, int f) - anc->hw_cylinders = characteristics->long_no_cyl; - else - anc->hw_cylinders = characteristics->no_cyl; -+ -+ anc->is_file = 0; - } - - anc->dev_type = dasd_info.dev_type; --- -1.9.3 - diff --git a/0099-libparted-mklabel-to-support-EDEV-DASD.patch b/0099-libparted-mklabel-to-support-EDEV-DASD.patch deleted file mode 100644 index 47b1b19..0000000 --- a/0099-libparted-mklabel-to-support-EDEV-DASD.patch +++ /dev/null @@ -1,56 +0,0 @@ -From bdb439f660344404f27084c48fe7b9429436b9e9 Mon Sep 17 00:00:00 2001 -From: Nageswara R Sastry -Date: Wed, 21 Aug 2013 16:37:17 -0700 -Subject: [PATCH 099/131] libparted: mklabel to support EDEV DASD - -Fixed Block Access (FBA) DASDs are mainframe-specific disk devices -which are layed out as a sequence of 512-byte sectors. This patch adds -support for mklabel to properly handle FBA devices. - -Signed-off-by: Nageswara R Sastry ---- - libparted/labels/fdasd.c | 28 +++++++++++++++------------- - 1 file changed, 15 insertions(+), 13 deletions(-) - -diff --git a/libparted/labels/fdasd.c b/libparted/labels/fdasd.c -index 7de5f34..1f87937 100644 ---- a/libparted/labels/fdasd.c -+++ b/libparted/labels/fdasd.c -@@ -870,19 +870,21 @@ fdasd_check_volume (fdasd_anchor_t *anc, int fd) - vtoc_read_volume_label (fd, anc->label_pos, v); - - if (strncmp(v->vollbl, vtoc_ebcdic_enc ("VOL1", str, 4), 4) == 0) { -- /* found VOL1 volume label */ -- b = (cchhb2blk (&v->vtoc, &anc->geo) - 1) * anc->blksize; -- -- if (b > 0) { -- int rc; -- rc = fdasd_valid_vtoc_pointer (anc, b, fd); -- -- if (rc < 0) -- return 1; -- else -- return 0; -- } else { -- fdasd_invalid_vtoc_pointer(anc); -+ if (anc->FBA_layout != 1 ) { -+ /* found VOL1 volume label */ -+ b = (cchhb2blk (&v->vtoc, &anc->geo) - 1) * anc->blksize; -+ -+ if (b > 0) { -+ int rc; -+ rc = fdasd_valid_vtoc_pointer (anc, b, fd); -+ -+ if (rc < 0) -+ return 1; -+ else -+ return 0; -+ } else { -+ fdasd_invalid_vtoc_pointer(anc); -+ } - } - } else if (strncmp (v->volkey, vtoc_ebcdic_enc ("LNX1", str, 4), 4) == 0 || - strncmp (v->volkey, vtoc_ebcdic_enc ("CMS1", str, 4), 4) == 0) { --- -1.9.3 - diff --git a/0100-dasd-avoid-usage-of-uninitialized-data.patch b/0100-dasd-avoid-usage-of-uninitialized-data.patch deleted file mode 100644 index 1051ec4..0000000 --- a/0100-dasd-avoid-usage-of-uninitialized-data.patch +++ /dev/null @@ -1,31 +0,0 @@ -From 97be947a7ed80dbd0ad29a56ab03c491904c2af8 Mon Sep 17 00:00:00 2001 -From: Petr Uzel -Date: Thu, 27 Mar 2014 08:31:42 +0100 -Subject: [PATCH 100/131] dasd: avoid usage of uninitialized data - -In ped_partition_new(), disk_specific data of PedPartition -structure is allocated (via dasd_partition_new()). This -data is later used uninitialized in dasd_partition_set_system(). - -* libparted/labels/dasd.c (dasd_partition_new): -Zero out allocated disk_specific data. ---- - libparted/labels/dasd.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/libparted/labels/dasd.c b/libparted/labels/dasd.c -index 081b3c5..c09b1d0 100644 ---- a/libparted/labels/dasd.c -+++ b/libparted/labels/dasd.c -@@ -699,7 +699,7 @@ dasd_partition_new (const PedDisk* disk, PedPartitionType part_type, - if (!part) - goto error; - -- part->disk_specific = ped_malloc (sizeof (DasdPartitionData)); -+ part->disk_specific = ped_calloc (sizeof (DasdPartitionData)); - return part; - - error: --- -1.9.3 - diff --git a/0101-Update-NEWS-with-new-DASD-features.patch b/0101-Update-NEWS-with-new-DASD-features.patch deleted file mode 100644 index 8821b5f..0000000 --- a/0101-Update-NEWS-with-new-DASD-features.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 16bc3c1ea807f7a506d0500ba2de16686bee3426 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 29 Apr 2014 11:38:35 -0700 -Subject: [PATCH 101/131] Update NEWS with new DASD features. - -* NEWS: New DASD support ---- - NEWS | 6 ++++++ - 1 file changed, 6 insertions(+) - -diff --git a/NEWS b/NEWS -index ae65106..c4c8f24 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,12 @@ GNU parted NEWS -*- outline -*- - - ** New Features - -+ Add support for EAV DASD partitions, which are ECKD's with more than -+ 65520 cylinders. -+ -+ Add support for implicit FBA DASD partitions with a single immutable -+ partition. -+ - Added support for recognizing btrfs filesystem. This simply displays - btrfs in the 'file system' column of the parted output. - --- -1.9.3 - diff --git a/0102-GPT-strings-are-UCS-2LE-not-UTF-16.patch b/0102-GPT-strings-are-UCS-2LE-not-UTF-16.patch deleted file mode 100644 index cfad2db..0000000 --- a/0102-GPT-strings-are-UCS-2LE-not-UTF-16.patch +++ /dev/null @@ -1,106 +0,0 @@ -From d80457356f41f1abdf84733923113087068e9bca Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Fri, 16 May 2014 10:23:28 -0700 -Subject: [PATCH 102/131] GPT strings are UCS-2LE not UTF-16 - -There was a problem using UTF-16, it was writing the Byte Order Mark -before the string which caused problems with older versions of parted -reading the partition name. The test was skipping these 2 bytes when -checking the written string. - -* libparted/labels/gpt.c: Switch to UCS-2LE for GPT Partition names -* tests/t0251-gpt-unicode.sh: Update the test ---- - libparted/labels/gpt.c | 22 ++++++++++------------ - tests/t0251-gpt-unicode.sh | 2 +- - 2 files changed, 11 insertions(+), 13 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 5c8df59..82eb58d 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -819,8 +819,7 @@ _parse_part_entry (PedDisk *disk, GuidPartitionEntry_t *pte) - gpt_part_data->type = pte->PartitionTypeGuid; - gpt_part_data->uuid = pte->UniquePartitionGuid; - for (i = 0; i < 36; i++) -- gpt_part_data->name[i] = -- (efi_char16_t) PED_LE16_TO_CPU ((uint16_t) pte->PartitionName[i]); -+ gpt_part_data->name[i] = (efi_char16_t) pte->PartitionName[i]; - gpt_part_data->name[i] = 0; - gpt_part_data->translated_name = 0; - -@@ -1237,8 +1236,7 @@ _partition_generate_part_entry (PedPartition *part, GuidPartitionEntry_t *pte) - pte->Attributes.LegacyBIOSBootable = 1; - - for (i = 0; i < 36; i++) -- pte->PartitionName[i] -- = (efi_char16_t) PED_CPU_TO_LE16 ((uint16_t) gpt_part_data->name[i]); -+ pte->PartitionName[i] = gpt_part_data->name[i]; - } - - static int -@@ -1889,7 +1887,7 @@ gpt_partition_set_name (PedPartition *part, const char *name) - - free(gpt_part_data->translated_name); - gpt_part_data->translated_name = xstrdup(name); -- iconv_t conv = iconv_open ("UTF-16", nl_langinfo (CODESET)); -+ iconv_t conv = iconv_open ("UCS-2LE", nl_langinfo (CODESET)); - if (conv == (iconv_t)-1) - goto err; - char *inbuff = gpt_part_data->translated_name; -@@ -1902,8 +1900,8 @@ gpt_partition_set_name (PedPartition *part, const char *name) - return; - err: - ped_exception_throw (PED_EXCEPTION_WARNING, -- PED_EXCEPTION_IGNORE, -- _("Can not translate partition name")); -+ PED_EXCEPTION_IGNORE, -+ _("Can not translate partition name")); - iconv_close (conv); - } - -@@ -1914,23 +1912,23 @@ gpt_partition_get_name (const PedPartition *part) - if (gpt_part_data->translated_name == NULL) - { - char buffer[200]; -- iconv_t conv = iconv_open (nl_langinfo (CODESET), "UTF-16"); -+ iconv_t conv = iconv_open (nl_langinfo (CODESET), "UCS-2LE"); - if (conv == (iconv_t)-1) -- goto err; -+ goto err; - char *inbuff = (char *)&gpt_part_data->name; - char *outbuff = buffer; - size_t inbuffsize = 72; - size_t outbuffsize = sizeof(buffer); - if (iconv (conv, &inbuff, &inbuffsize, &outbuff, &outbuffsize) == -1) -- goto err; -+ goto err; - iconv_close (conv); - *outbuff = 0; - gpt_part_data->translated_name = xstrdup (buffer); - return gpt_part_data->translated_name; - err: - ped_exception_throw (PED_EXCEPTION_WARNING, -- PED_EXCEPTION_IGNORE, -- _("Can not translate partition name")); -+ PED_EXCEPTION_IGNORE, -+ _("Can not translate partition name")); - iconv_close (conv); - return ""; - } -diff --git a/tests/t0251-gpt-unicode.sh b/tests/t0251-gpt-unicode.sh -index 36a4c26..fbffbcb 100755 ---- a/tests/t0251-gpt-unicode.sh -+++ b/tests/t0251-gpt-unicode.sh -@@ -31,7 +31,7 @@ parted -s $dev mklabel gpt mkpart primary ext2 1MiB 2MiB name 1 $part_name > emp - compare /dev/null empty || fail=1 - - # check for expected output --dd if=$dev bs=1 skip=$(($sector_size_+$sector_size_+58)) count=10 2>/dev/null | od -An -tx1 > out || fail=1 -+dd if=$dev bs=1 skip=$(($sector_size_+$sector_size_+56)) count=10 2>/dev/null | od -An -tx1 > out || fail=1 - echo ' 66 00 6f 00 6f 00 24 1d 00 00' >> exp - compare exp out || fail=1 - --- -1.9.3 - diff --git a/0103-libparted-fix-fat-resize.patch b/0103-libparted-fix-fat-resize.patch deleted file mode 100644 index 583789f..0000000 --- a/0103-libparted-fix-fat-resize.patch +++ /dev/null @@ -1,60 +0,0 @@ -From 5adae27101565a5d6fed4aadf28ddb39872e41f5 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Fri, 18 Apr 2014 17:00:02 -0400 -Subject: [PATCH 103/131] libparted: fix fat resize - -The changes to fix filesystem detection on non 512 byte sector sizes broke -fat filesystem resizing. ---- - libparted/fs/r/fat/fat.c | 6 +++++- - libparted/fs/r/fat/resize.c | 10 ++++++---- - 2 files changed, 11 insertions(+), 5 deletions(-) - -diff --git a/libparted/fs/r/fat/fat.c b/libparted/fs/r/fat/fat.c -index fdc1ecc..8d7420b 100644 ---- a/libparted/fs/r/fat/fat.c -+++ b/libparted/fs/r/fat/fat.c -@@ -35,7 +35,9 @@ fat_alloc (const PedGeometry* geom) - fs->type_specific = (FatSpecific*) ped_malloc (sizeof (FatSpecific)); - if (!fs->type_specific) - goto error_free_fs; -- -+ FatSpecific* fs_info = (FatSpecific*) fs->type_specific; -+ fs_info->boot_sector = NULL; -+ fs_info->info_sector = NULL; - fs->geom = ped_geometry_duplicate (geom); - if (!fs->geom) - goto error_free_type_specific; -@@ -86,6 +88,8 @@ fat_free_buffers (PedFileSystem* fs) - void - fat_free (PedFileSystem* fs) - { -+ FatSpecific* fs_info = (FatSpecific*) fs->type_specific; -+ free (fs_info->boot_sector); - ped_geometry_destroy (fs->geom); - free (fs->type_specific); - free (fs); -diff --git a/libparted/fs/r/fat/resize.c b/libparted/fs/r/fat/resize.c -index f3439ac..046382b 100644 ---- a/libparted/fs/r/fat/resize.c -+++ b/libparted/fs/r/fat/resize.c -@@ -667,10 +667,12 @@ create_resize_context (PedFileSystem* fs, const PedGeometry* new_geom) - goto error_free_new_fs; - - /* preserve boot code, etc. */ -- memcpy (&new_fs_info->boot_sector, &fs_info->boot_sector, -- sizeof (FatBootSector)); -- memcpy (&new_fs_info->info_sector, &fs_info->info_sector, -- sizeof (FatInfoSector)); -+ new_fs_info->boot_sector = ped_malloc (new_geom->dev->sector_size); -+ new_fs_info->info_sector = ped_malloc (new_geom->dev->sector_size); -+ memcpy (new_fs_info->boot_sector, fs_info->boot_sector, -+ new_geom->dev->sector_size); -+ memcpy (new_fs_info->info_sector, fs_info->info_sector, -+ new_geom->dev->sector_size); - - new_fs_info->logical_sector_size = fs_info->logical_sector_size; - new_fs_info->sector_count = new_geom->length; --- -1.9.3 - diff --git a/0104-parted-don-t-reload-partition-table-on-every-command.patch b/0104-parted-don-t-reload-partition-table-on-every-command.patch deleted file mode 100644 index 2f27d74..0000000 --- a/0104-parted-don-t-reload-partition-table-on-every-command.patch +++ /dev/null @@ -1,951 +0,0 @@ -From 7eac0588b68a4d991a0f861bb9f4553f44557e14 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 5 Jan 2014 23:02:44 -0500 -Subject: [PATCH 104/131] parted: don't reload partition table on every command - -gpt was using a static local variable to suppress repeatedly reporting -an error if you chose to ignore it. This is incorrect as the variable is -global to all disks, and ignoring the error on one should not suppress its -reporting on another. Moving the flag to the PedDisk object made it -effectively useless because parted was destroying the PedDisk and reloading -the partition table on every command. - -Parted has been reworked to cache the PedDisk once loaded, and only discard -it when changing disks, or creating a new disklabel. ---- - NEWS | 5 + - libparted/labels/gpt.c | 7 +- - parted/command.c | 6 +- - parted/command.h | 6 +- - parted/parted.c | 291 +++++++++++++++++++------------------- - parted/ui.c | 8 +- - parted/ui.h | 8 +- - tests/t0283-overlap-partitions.sh | 6 - - tests/t3300-palo-prep.sh | 8 +- - 9 files changed, 170 insertions(+), 175 deletions(-) - -diff --git a/NEWS b/NEWS -index c4c8f24..8e2a1b9 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,11 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: previously if you chose to ignore the warning about -+ the gpt thinking the disk was smaller than it appears to be on -+ on disk, subsequent warnings on other disks would be suppressed. -+ Now parted will warn once per disk. -+ - Fix filesystem detection on non 512 byte sector sizes - - Fix linux partition sync code to flush partitions > 16 -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 82eb58d..76bf7e7 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -724,7 +724,6 @@ _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - PedSector first_usable; - PedSector last_usable; - PedSector last_usable_if_grown; -- static int asked_already; - - #ifndef DISCOVER_ONLY - if (PED_LE32_TO_CPU (gpt->Revision) > GPT_HEADER_REVISION_V1_02) -@@ -761,7 +760,7 @@ _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - || disk->dev->length < last_usable_if_grown) - return 0; - -- if (!asked_already && last_usable < last_usable_if_grown) -+ if (last_usable < last_usable_if_grown) - { - PedExceptionOption q; - -@@ -783,10 +782,6 @@ _parse_header (PedDisk *disk, const GuidPartitionTableHeader_t *gpt, - gpt_disk_data->AlternateLBA = disk->dev->length - 1; - *update_needed = 1; - } -- else if (q != PED_EXCEPTION_UNHANDLED) -- { -- asked_already = 1; -- } - } - - ped_geometry_init (&gpt_disk_data->data_area, disk->dev, -diff --git a/parted/command.c b/parted/command.c -index e91c0c6..c592248 100644 ---- a/parted/command.c -+++ b/parted/command.c -@@ -28,7 +28,7 @@ - - Command* - command_create (const StrList* names, -- int (*method) (PedDevice** dev), -+ int (*method) (PedDevice** dev, PedDisk** diskp), - const StrList* summary, - const StrList* help, - const int non_interactive) -@@ -134,7 +134,7 @@ command_print_help (Command* cmd) - } - - int --command_run (Command* cmd, PedDevice** dev) -+command_run (Command* cmd, PedDevice** dev, PedDisk** diskp) - { -- return cmd->method (dev); -+ return cmd->method (dev, diskp); - } -diff --git a/parted/command.h b/parted/command.h -index fed7a23..0fe43aa 100644 ---- a/parted/command.h -+++ b/parted/command.h -@@ -24,14 +24,14 @@ - - typedef struct { - StrList* names; -- int (*method) (PedDevice** dev); -+ int (*method) (PedDevice** dev, PedDisk** diskp); - StrList* summary; - StrList* help; - int non_interactive:1; - } Command; - - extern Command* command_create (const StrList* names, -- int (*method) (PedDevice** dev), -+ int (*method) (PedDevice** dev, PedDisk** diskp), - const StrList* summary, - const StrList* help, - int non_interactive); -@@ -42,6 +42,6 @@ extern Command* command_get (Command** list, char* name); - extern StrList* command_get_names (Command** list); - extern void command_print_summary (Command* cmd); - extern void command_print_help (Command* cmd); --extern int command_run (Command* cmd, PedDevice** dev); -+extern int command_run (Command* cmd, PedDevice** dev, PedDisk** diskp); - - #endif /* COMMAND_H_INCLUDED */ -diff --git a/parted/parted.c b/parted/parted.c -index a7d9363..7a53586 100644 ---- a/parted/parted.c -+++ b/parted/parted.c -@@ -178,7 +178,7 @@ static PedTimer* g_timer; - static TimerContext timer_context; - - static int _print_list (); --static void _done (PedDevice* dev); -+static void _done (PedDevice* dev, PedDisk *diskp); - static bool partition_align_check (PedDisk const *disk, - PedPartition const *part, enum AlignmentType a_type); - -@@ -471,7 +471,7 @@ print_options_help () - } - - int --do_help (PedDevice** dev) -+do_help (PedDevice** dev, PedDisk** diskp) - { - if (command_line_get_word_count ()) { - char* word = command_line_pop_word (); -@@ -486,26 +486,28 @@ do_help (PedDevice** dev) - } - - static int --do_mklabel (PedDevice** dev) -+do_mklabel (PedDevice** dev, PedDisk** diskp) - { - PedDisk* disk; - const PedDiskType* type = NULL; - -- ped_exception_fetch_all (); -- disk = ped_disk_new (*dev); -- if (!disk) ped_exception_catch (); -- ped_exception_leave_all (); -+ if (*diskp) -+ disk = *diskp; -+ else { -+ ped_exception_fetch_all (); -+ disk = ped_disk_new (*dev); -+ if (!disk) ped_exception_catch (); -+ ped_exception_leave_all (); -+ } - - if (!command_line_get_disk_type (_("New disk label type?"), &type)) - goto error; - - if (disk) { - if (!_disk_warn_busy (disk)) -- goto error_destroy_disk; -+ goto error; - if (!opt_script_mode && !_disk_warn_loss (disk)) -- goto error_destroy_disk; -- -- ped_disk_destroy (disk); -+ goto error; - } - - disk = ped_disk_new_fresh (*dev, type); -@@ -514,15 +516,17 @@ do_mklabel (PedDevice** dev) - - if (!ped_disk_commit (disk)) - goto error_destroy_disk; -- ped_disk_destroy (disk); - - if ((*dev)->type != PED_DEVICE_FILE) - disk_is_modified = 1; -- -+ if (*diskp) -+ ped_disk_destroy (*diskp); -+ *diskp = disk; - return 1; - - error_destroy_disk: - ped_disk_destroy (disk); -+ *diskp = 0; - error: - return 0; - } -@@ -600,7 +604,7 @@ _adjust_end_if_iec (PedSector* start, PedSector* end, - } - - static int --do_mkpart (PedDevice** dev) -+do_mkpart (PedDevice** dev, PedDisk** diskp) - { - PedDisk* disk; - PedPartition* part; -@@ -616,21 +620,26 @@ do_mkpart (PedDevice** dev) - char *start_usr = NULL, *end_usr = NULL; - char *start_sol = NULL, *end_sol = NULL; - -- disk = ped_disk_new (*dev); -+ if (*diskp) -+ disk = *diskp; -+ else { -+ disk = ped_disk_new (*dev); -+ *diskp = disk; -+ } - if (!disk) - goto error; - - if (ped_disk_is_flag_available(disk, PED_DISK_CYLINDER_ALIGNMENT)) - if (!ped_disk_set_flag(disk, PED_DISK_CYLINDER_ALIGNMENT, - alignment == ALIGNMENT_CYLINDER)) -- goto error_destroy_disk; -+ goto error; - - if (!ped_disk_type_check_feature (disk->type, PED_DISK_TYPE_EXTENDED)) { - part_type = PED_PARTITION_NORMAL; - } else { - if (!command_line_get_part_type (_("Partition type?"), - disk, &part_type)) -- goto error_destroy_disk; -+ goto error; - } - - /* The undocumented feature that mkpart sometimes takes a -@@ -656,15 +665,15 @@ do_mkpart (PedDevice** dev) - } else { - if (!command_line_get_fs_type (_("File system type?"), - &fs_type)) -- goto error_destroy_disk; -+ goto error; - } - free (peek_word); - - if (!command_line_get_sector (_("Start?"), *dev, &start, &range_start, NULL)) -- goto error_destroy_disk; -+ goto error; - char *end_input; - if (!command_line_get_sector (_("End?"), *dev, &end, &range_end, &end_input)) -- goto error_destroy_disk; -+ goto error; - - _adjust_end_if_iec(&start, &end, range_end, end_input); - free(end_input); -@@ -672,7 +681,7 @@ do_mkpart (PedDevice** dev) - /* processing starts here */ - part = ped_partition_new (disk, part_type, fs_type, start, end); - if (!part) -- goto error_destroy_disk; -+ goto error; - - snap_to_boundaries (&part->geom, NULL, disk, range_start, range_end); - -@@ -780,16 +789,14 @@ do_mkpart (PedDevice** dev) - free (part_name); /* avoid double-free upon failure */ - part_name = NULL; - if (!ped_partition_set_system (part, fs_type)) -- goto error_destroy_disk; -+ goto error; - if (ped_partition_is_flag_available (part, PED_PARTITION_LBA)) - ped_partition_set_flag (part, PED_PARTITION_LBA, 1); - - if (!ped_disk_commit (disk)) -- goto error_destroy_disk; -+ goto error; - - /* clean up */ -- ped_disk_destroy (disk); -- - if (range_start != NULL) - ped_geometry_destroy (range_start); - if (range_end != NULL) -@@ -809,10 +816,8 @@ error_remove_part: - ped_disk_remove_partition (disk, part); - error_destroy_simple_constraints: - ped_partition_destroy (part); --error_destroy_disk: -- free (part_name); -- ped_disk_destroy (disk); - error: -+ free (part_name); - if (range_start != NULL) - ped_geometry_destroy (range_start); - if (range_end != NULL) -@@ -827,36 +832,33 @@ error: - } - - static int --do_name (PedDevice** dev) -+do_name (PedDevice** dev, PedDisk** diskp) - { -- PedDisk* disk; - PedPartition* part = NULL; - char* name; - -- disk = ped_disk_new (*dev); -- if (!disk) -+ if (!*diskp) -+ *diskp = ped_disk_new (*dev); -+ if (!diskp) - goto error; - -- if (!command_line_get_partition (_("Partition number?"), disk, &part)) -- goto error_destroy_disk; -+ if (!command_line_get_partition (_("Partition number?"), *diskp, &part)) -+ goto error; - - name = command_line_get_word (_("Partition name?"), - ped_partition_get_name (part), NULL, 0); - if (!name) -- goto error_destroy_disk; -+ goto error; - if (!ped_partition_set_name (part, name)) - goto error_free_name; - free (name); - -- if (!ped_disk_commit (disk)) -- goto error_destroy_disk; -- ped_disk_destroy (disk); -+ if (!ped_disk_commit (*diskp)) -+ goto error; - return 1; - - error_free_name: - free (name); --error_destroy_disk: -- ped_disk_destroy (disk); - error: - return 0; - } -@@ -943,7 +945,7 @@ _print_disk_geometry (const PedDevice *dev) - } - - static void --_print_disk_info (const PedDevice *dev, const PedDisk *disk) -+_print_disk_info (const PedDevice *dev, const PedDisk *diskp) - { - char const *const transport[] = {"unknown", "scsi", "ide", "dac960", - "cpqarray", "file", "ataraid", "i2o", -@@ -957,8 +959,8 @@ _print_disk_info (const PedDevice *dev, const PedDisk *disk) - - (default_unit == PED_UNIT_CHS || - default_unit == PED_UNIT_CYLINDER)); - -- const char* pt_name = disk ? disk->type->name : "unknown"; -- char *disk_flags = disk_print_flags (disk); -+ const char* pt_name = diskp ? diskp->type->name : "unknown"; -+ char *disk_flags = disk_print_flags (diskp); - - if (opt_machine_mode) { - switch (default_unit) { -@@ -997,9 +999,8 @@ _print_disk_info (const PedDevice *dev, const PedDisk *disk) - } - - static int --do_print (PedDevice** dev) -+do_print (PedDevice** dev, PedDisk** diskp) - { -- PedDisk* disk = NULL; - Table* table; - int has_extended; - int has_name; -@@ -1041,22 +1042,23 @@ do_print (PedDevice** dev) - } - - if (!has_devices_arg && !has_list_arg) { -- disk = ped_disk_new (*dev); -+ if (!*diskp) -+ *diskp = ped_disk_new (*dev); - /* Returning NULL here is an indication of failure, when in - script mode. Otherwise (interactive mode) it may indicate - a real error, but it may also indicate that the user - declined when asked to perform some operation. FIXME: - what this really needs is an API change, but a reliable - exit code is less important in interactive mode. */ -- if (disk == NULL && opt_script_mode) -+ if (*diskp == NULL && opt_script_mode) - ok = 0; - } - -- if (disk && -- ped_disk_is_flag_available(disk, PED_DISK_CYLINDER_ALIGNMENT)) -- if (!ped_disk_set_flag(disk, PED_DISK_CYLINDER_ALIGNMENT, -+ if (*diskp && -+ ped_disk_is_flag_available(*diskp, PED_DISK_CYLINDER_ALIGNMENT)) -+ if (!ped_disk_set_flag(*diskp, PED_DISK_CYLINDER_ALIGNMENT, - alignment == ALIGNMENT_CYLINDER)) -- goto error_destroy_disk; -+ return 0; - - if (has_devices_arg) { - char* dev_name; -@@ -1089,24 +1091,23 @@ do_print (PedDevice** dev) - else if (has_list_arg) - return _print_list (); - -- else if (disk && has_num_arg) { -+ else if (*diskp && has_num_arg) { - PedPartition* part = NULL; - int status = 0; -- if (command_line_get_partition ("", disk, &part)) -+ if (command_line_get_partition ("", *diskp, &part)) - status = partition_print (part); -- ped_disk_destroy (disk); - return status; - } - -- _print_disk_info (*dev, disk); -- if (!disk) -+ _print_disk_info (*dev, *diskp); -+ if (!*diskp) - goto nopt; - if (!opt_machine_mode) - putchar ('\n'); - -- has_extended = ped_disk_type_check_feature (disk->type, -+ has_extended = ped_disk_type_check_feature ((*diskp)->type, - PED_DISK_TYPE_EXTENDED); -- has_name = ped_disk_type_check_feature (disk->type, -+ has_name = ped_disk_type_check_feature ((*diskp)->type, - PED_DISK_TYPE_PARTITION_NAME); - - PedPartition* part; -@@ -1136,8 +1137,8 @@ do_print (PedDevice** dev) - - table_add_row_from_strlist (table, row1); - -- for (part = ped_disk_next_partition (disk, NULL); part; -- part = ped_disk_next_partition (disk, part)) { -+ for (part = ped_disk_next_partition (*diskp, NULL); part; -+ part = ped_disk_next_partition (*diskp, part)) { - - if ((!has_free_arg && !ped_partition_is_active(part)) || - part->type & PED_PARTITION_METADATA) -@@ -1212,8 +1213,8 @@ do_print (PedDevice** dev) - - } else { - -- for (part = ped_disk_next_partition (disk, NULL); part; -- part = ped_disk_next_partition (disk, part)) { -+ for (part = ped_disk_next_partition (*diskp, NULL); part; -+ part = ped_disk_next_partition (*diskp, part)) { - - if ((!has_free_arg && !ped_partition_is_active(part)) || - part->type & PED_PARTITION_METADATA) -@@ -1261,13 +1262,8 @@ do_print (PedDevice** dev) - } - } - -- ped_disk_destroy (disk); -- - return ok; - --error_destroy_disk: -- ped_disk_destroy (disk); -- return 0; - nopt: - return ok; - } -@@ -1276,11 +1272,15 @@ static int - _print_list () - { - PedDevice *current_dev = NULL; -+ PedDisk *diskp = NULL; - - ped_device_probe_all(); - - while ((current_dev = ped_device_get_next(current_dev))) { -- do_print (¤t_dev); -+ do_print (¤t_dev, &diskp); -+ if (diskp) -+ ped_disk_destroy (diskp); -+ diskp = 0; - putchar ('\n'); - } - -@@ -1288,9 +1288,9 @@ _print_list () - } - - static int --do_quit (PedDevice** dev) -+do_quit (PedDevice** dev, PedDisk **diskp) - { -- _done (*dev); -+ _done (*dev, *diskp); - exit (EXIT_SUCCESS); - } - -@@ -1436,7 +1436,7 @@ error_remove_partition: - } - - static int --do_rescue (PedDevice** dev) -+do_rescue (PedDevice** dev, PedDisk** diskp) - { - PedDisk* disk; - PedSector start = 0, end = 0; -@@ -1444,6 +1444,10 @@ do_rescue (PedDevice** dev) - PedGeometry probe_start_region; - PedGeometry probe_end_region; - -+ if (*diskp) { -+ ped_disk_destroy (*diskp); -+ *diskp = 0; -+ } - disk = ped_disk_new (*dev); - if (!disk) - goto error; -@@ -1480,37 +1484,34 @@ error: - } - - static int --do_rm (PedDevice** dev) -+do_rm (PedDevice** dev, PedDisk** diskp) - { -- PedDisk* disk; - PedPartition* part = NULL; - -- disk = ped_disk_new (*dev); -- if (!disk) -+ if (!*diskp) -+ *diskp = ped_disk_new (*dev); -+ if (!*diskp) - goto error; - -- if (!command_line_get_partition (_("Partition number?"), disk, &part)) -- goto error_destroy_disk; -+ if (!command_line_get_partition (_("Partition number?"), *diskp, &part)) -+ goto error; - if (!_partition_warn_busy (part)) -- goto error_destroy_disk; -+ goto error; - -- ped_disk_delete_partition (disk, part); -- ped_disk_commit (disk); -- ped_disk_destroy (disk); -+ ped_disk_delete_partition (*diskp, part); -+ ped_disk_commit (*diskp); - - if ((*dev)->type != PED_DEVICE_FILE) - disk_is_modified = 1; - - return 1; - --error_destroy_disk: -- ped_disk_destroy (disk); - error: - return 0; - } - - static int --do_select (PedDevice** dev) -+do_select (PedDevice** dev, PedDisk** diskp) - { - PedDevice* new_dev = *dev; - -@@ -1520,6 +1521,10 @@ do_select (PedDevice** dev) - return 0; - - ped_device_close (*dev); -+ if (*diskp) { -+ ped_disk_destroy (*diskp); -+ *diskp = 0; -+ } - *dev = new_dev; - print_using_dev (*dev); - return 1; -@@ -1550,26 +1555,25 @@ partition_align_check (PedDisk const *disk, PedPartition const *part, - } - - static int --do_align_check (PedDevice **dev) -+do_align_check (PedDevice **dev, PedDisk** diskp) - { -- PedDisk *disk = ped_disk_new (*dev); -- if (!disk) -+ if (!*diskp) -+ *diskp = ped_disk_new (*dev); -+ if (!*diskp) - goto error; - - enum AlignmentType align_type = PA_OPTIMUM; - PedPartition *part = NULL; - - if (!command_line_get_align_type (_("alignment type(min/opt)"), &align_type)) -- goto error_destroy_disk; -- if (!command_line_get_partition (_("Partition number?"), disk, &part)) -- goto error_destroy_disk; -+ goto error; -+ if (!command_line_get_partition (_("Partition number?"), *diskp, &part)) -+ goto error; - -- bool aligned = partition_align_check (disk, part, align_type); -+ bool aligned = partition_align_check (*diskp, part, align_type); - if (!opt_script_mode) - printf(aligned ? _("%d aligned\n") : _("%d not aligned\n"), part->num); - -- ped_disk_destroy (disk); -- - if (opt_script_mode) - return aligned ? 1 : 0; - -@@ -1577,115 +1581,107 @@ do_align_check (PedDevice **dev) - with the other modes. */ - return 1; - --error_destroy_disk: -- ped_disk_destroy (disk); - error: - return 0; - } - - static int --do_disk_set (PedDevice** dev) -+do_disk_set (PedDevice** dev, PedDisk** diskp) - { -- PedDisk* disk; - PedDiskFlag flag; - int state; - -- disk = ped_disk_new (*dev); -- if (!disk) -+ if (!*diskp) -+ *diskp = ped_disk_new (*dev); -+ if (!diskp) - goto error; - -- if (!command_line_get_disk_flag (_("Flag to Invert?"), disk, &flag)) -- goto error_destroy_disk; -- state = (ped_disk_get_flag (disk, flag) == 0 ? 1 : 0); -+ if (!command_line_get_disk_flag (_("Flag to Invert?"), *diskp, &flag)) -+ goto error; -+ state = (ped_disk_get_flag (*diskp, flag) == 0 ? 1 : 0); - - if (!is_toggle_mode) { - if (!command_line_get_state (_("New state?"), &state)) -- goto error_destroy_disk; -+ goto error; - } - -- if (!ped_disk_set_flag (disk, flag, state)) -- goto error_destroy_disk; -- if (!ped_disk_commit (disk)) -- goto error_destroy_disk; -- ped_disk_destroy (disk); -+ if (!ped_disk_set_flag (*diskp, flag, state)) -+ goto error; -+ if (!ped_disk_commit (*diskp)) -+ goto error; - - if ((*dev)->type != PED_DEVICE_FILE) - disk_is_modified = 1; - - return 1; - --error_destroy_disk: -- ped_disk_destroy (disk); - error: - return 0; - } - - static int --do_set (PedDevice** dev) -+do_set (PedDevice** dev, PedDisk **diskp) - { -- PedDisk* disk; - PedPartition* part = NULL; - PedPartitionFlag flag; - int state; - -- disk = ped_disk_new (*dev); -- if (!disk) -+ if (*diskp == 0) -+ *diskp = ped_disk_new (*dev); -+ if (!*diskp) - goto error; - -- if (!command_line_get_partition (_("Partition number?"), disk, &part)) -- goto error_destroy_disk; -+ if (!command_line_get_partition (_("Partition number?"), *diskp, &part)) -+ goto error; - if (!command_line_get_part_flag (_("Flag to Invert?"), part, &flag)) -- goto error_destroy_disk; -+ goto error; - state = (ped_partition_get_flag (part, flag) == 0 ? 1 : 0); - - if (!is_toggle_mode) { - if (!command_line_get_state (_("New state?"), &state)) -- goto error_destroy_disk; -+ goto error; - } - - if (!ped_partition_set_flag (part, flag, state)) -- goto error_destroy_disk; -- if (!ped_disk_commit (disk)) -- goto error_destroy_disk; -- ped_disk_destroy (disk); -+ goto error; -+ if (!ped_disk_commit (*diskp)) -+ goto error; - - if ((*dev)->type != PED_DEVICE_FILE) - disk_is_modified = 1; - -- return 1; -+ return 1; - --error_destroy_disk: -- ped_disk_destroy (disk); - error: - return 0; - } - - static int --do_disk_toggle (PedDevice **dev) -+do_disk_toggle (PedDevice **dev, PedDisk** diskp) - { - int result; - - is_toggle_mode = 1; -- result = do_disk_set (dev); -+ result = do_disk_set (dev, diskp); - is_toggle_mode = 0; - - return result; - } - - static int --do_toggle (PedDevice **dev) -+do_toggle (PedDevice **dev, PedDisk** diskp) - { - int result; - - is_toggle_mode = 1; -- result = do_set (dev); -+ result = do_set (dev, diskp); - is_toggle_mode = 0; - - return result; - } - - static int --do_unit (PedDevice** dev) -+do_unit (PedDevice** dev, PedDisk** diskp) - { - PedUnit unit = ped_unit_get_default (); - if (!command_line_get_unit (_("Unit?"), &unit)) -@@ -2150,20 +2146,22 @@ return NULL; - } - - static void --_done (PedDevice* dev) -+_done (PedDevice* dev, PedDisk* diskp) - { --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.")); --} --if (!opt_script_mode && !opt_machine_mode && disk_is_modified) { -- ped_exception_throw ( -- PED_EXCEPTION_INFORMATION, PED_EXCEPTION_OK, -- _("You may need to update /etc/fstab.\n")); -+ if (diskp) -+ ped_disk_destroy (diskp); -+ 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.")); -+ } -+ if (!opt_script_mode && !opt_machine_mode && disk_is_modified) { -+ ped_exception_throw ( -+ PED_EXCEPTION_INFORMATION, PED_EXCEPTION_OK, -+ _("You may need to update /etc/fstab.\n")); - } - - ped_device_close (dev); -@@ -2178,6 +2176,7 @@ int - main (int argc, char** argv) - { - PedDevice* dev; -+ PedDisk* diskp = 0; - int status; - - set_program_name (argv[0]); -@@ -2188,11 +2187,11 @@ main (int argc, char** argv) - return 1; - - if (argc || opt_script_mode) -- status = non_interactive_mode (&dev, commands, argc, argv); -+ status = non_interactive_mode (&dev, &diskp, commands, argc, argv); - else -- status = interactive_mode (&dev, commands); -+ status = interactive_mode (&dev, &diskp, commands); - -- _done (dev); -+ _done (dev, diskp); - - return !status; - } -diff --git a/parted/ui.c b/parted/ui.c -index b33f6fc..925110d 100644 ---- a/parted/ui.c -+++ b/parted/ui.c -@@ -1557,7 +1557,7 @@ print_using_dev (PedDevice* dev) - } - - int --interactive_mode (PedDevice** dev, Command* cmd_list[]) -+interactive_mode (PedDevice** dev, PedDisk** disk, Command* cmd_list[]) - { - StrList* list; - StrList* command_names = command_get_names (cmd_list); -@@ -1590,7 +1590,7 @@ interactive_mode (PedDevice** dev, Command* cmd_list[]) - cmd = command_get (commands, word); - free (word); - if (cmd) { -- if (!command_run (cmd, dev)) -+ if (!command_run (cmd, dev, disk)) - command_line_flush (); - } else - print_commands_help (); -@@ -1602,7 +1602,7 @@ interactive_mode (PedDevice** dev, Command* cmd_list[]) - - - int --non_interactive_mode (PedDevice** dev, Command* cmd_list[], -+non_interactive_mode (PedDevice** dev, PedDisk **disk, Command* cmd_list[], - int argc, char* argv[]) - { - int i; -@@ -1633,7 +1633,7 @@ non_interactive_mode (PedDevice** dev, Command* cmd_list[], - goto error; - } - -- if (!command_run (cmd, dev)) -+ if (!command_run (cmd, dev, disk)) - goto error; - } - return 1; -diff --git a/parted/ui.h b/parted/ui.h -index 3c6ebc0..260ce37 100644 ---- a/parted/ui.h -+++ b/parted/ui.h -@@ -31,9 +31,11 @@ extern const char *prog_name; - - extern int init_ui (); - extern int init_readline (); --extern int non_interactive_mode (PedDevice** dev, Command* cmd_list[], -- int argc, char* argv[]); --extern int interactive_mode (PedDevice** dev, Command* cmd_list[]); -+extern int non_interactive_mode (PedDevice** dev, PedDisk **disk, -+ Command* cmd_list[], int argc, -+ char* argv[]); -+extern int interactive_mode (PedDevice** dev, PedDisk **disk, -+ Command* cmd_list[]); - extern void done_ui (); - - extern int screen_width (); -diff --git a/tests/t0283-overlap-partitions.sh b/tests/t0283-overlap-partitions.sh -index 221332d..76b2740 100644 ---- a/tests/t0283-overlap-partitions.sh -+++ b/tests/t0283-overlap-partitions.sh -@@ -30,7 +30,6 @@ parted ---pretend-input-tty $dev < out 2>&1 || fail=1 - print - ignore - rm --ignore - 2 - EOF - -@@ -59,8 +58,6 @@ Number Start End Size Type File system Flags - 2 5242kB 8000kB 2758kB primary - - (parted) rm --Error: Can't have overlapping partitions. --Ignore/Cancel? ignore - Partition number? 2 - (parted) - EOF -@@ -73,7 +70,6 @@ parted ---pretend-input-tty $dev < out 2>&1 || fail=1 - print - ignore - rm --ignore - 1 - EOF - -@@ -101,8 +97,6 @@ Number Start End Size Type File system Flags - 1 1049kB 5243kB 4194kB primary - - (parted) rm --Error: Can't have a partition outside the disk! --Ignore/Cancel? ignore - Partition number? 1 - (parted) - EOF -diff --git a/tests/t3300-palo-prep.sh b/tests/t3300-palo-prep.sh -index 4050414..88b2c55 100755 ---- a/tests/t3300-palo-prep.sh -+++ b/tests/t3300-palo-prep.sh -@@ -20,9 +20,9 @@ - ss=$sector_size_ - - cat > exp < out 2> err || fail=1 - --grep -E '^1:2048s:4095s:2048s:::p...;$' out > k; mv k out -+grep -E '^1:2048s:4095s:2048s:ext2::lba, p...;$' out > k; mv k out - - compare exp out || fail=1 - --- -1.9.3 - diff --git a/0105-libparted-don-t-detect-fat-and-ntfs-boot-sectors-as-.patch b/0105-libparted-don-t-detect-fat-and-ntfs-boot-sectors-as-.patch deleted file mode 100644 index 45833c8..0000000 --- a/0105-libparted-don-t-detect-fat-and-ntfs-boot-sectors-as-.patch +++ /dev/null @@ -1,107 +0,0 @@ -From 82eda230f252ddf2d5909eff3ab092c4af33eb60 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 26 Apr 2014 14:38:30 -0400 -Subject: [PATCH 105/131] libparted: don't detect fat and ntfs boot sectors as - dos MBR - -fat and ntfs boot sectors are very similar to an MBR so if you had one of -these filesystems on an unpartitioned disk, parted detected them as a dos -partition table. Have the dos label code call the fat and ntfs filesystem -probes and if they recognize the sector ( their tests are more stringent ) -then don't claim it as a dos label. ---- - NEWS | 3 +++ - libparted/fs/ntfs/ntfs.c | 2 +- - libparted/labels/dos.c | 29 +++++++++++++++++++++++++++++ - 3 files changed, 33 insertions(+), 1 deletion(-) - -diff --git a/NEWS b/NEWS -index 8e2a1b9..bc852e2 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: fat and ntfs boot sectors were misdetected as dos -+ partition tables instead of being treated as a loop label. -+ - libparted: previously if you chose to ignore the warning about - the gpt thinking the disk was smaller than it appears to be on - on disk, subsequent warnings on other disks would be suppressed. -diff --git a/libparted/fs/ntfs/ntfs.c b/libparted/fs/ntfs/ntfs.c -index 3ba2683..4c154fd 100644 ---- a/libparted/fs/ntfs/ntfs.c -+++ b/libparted/fs/ntfs/ntfs.c -@@ -32,7 +32,7 @@ - - #define NTFS_SIGNATURE "NTFS" - --static PedGeometry* -+PedGeometry* - ntfs_probe (PedGeometry* geom) - { - char *buf = alloca (geom->dev->sector_size); -diff --git a/libparted/labels/dos.c b/libparted/labels/dos.c -index eff1c03..295fcf3 100644 ---- a/libparted/labels/dos.c -+++ b/libparted/labels/dos.c -@@ -235,12 +235,23 @@ maybe_FAT (unsigned char const *s) - return true; - } - -+PedGeometry* -+fat_probe_fat16 (PedGeometry* geom); -+ -+PedGeometry* -+fat_probe_fat32 (PedGeometry* geom); -+ -+PedGeometry* -+ntfs_probe (PedGeometry* geom); -+ - static int - msdos_probe (const PedDevice *dev) - { - PedDiskType* disk_type; - DosRawTable* part_table; - int i; -+ PedGeometry *geom = NULL; -+ PedGeometry *fsgeom = NULL; - - PED_ASSERT (dev != NULL); - -@@ -257,6 +268,20 @@ msdos_probe (const PedDevice *dev) - if (PED_LE16_TO_CPU (part_table->magic) != MSDOS_MAGIC) - goto probe_fail; - -+ geom = ped_geometry_new (dev, 0, dev->length); -+ PED_ASSERT (geom); -+ fsgeom = fat_probe_fat16 (geom); -+ if (fsgeom) -+ goto probe_fail; /* fat fs looks like dos mbr */ -+ fsgeom = fat_probe_fat32 (geom); -+ if (fsgeom) -+ goto probe_fail; /* fat fs looks like dos mbr */ -+ fsgeom = ntfs_probe (geom); -+ if (fsgeom) -+ goto probe_fail; /* ntfs fs looks like dos mbr */ -+ ped_geometry_destroy (geom); -+ geom = NULL; -+ - /* If this is a FAT fs, fail here. Checking for the FAT signature - * has some false positives; instead, do what the Linux kernel does - * and ensure that each partition has a boot indicator that is -@@ -303,6 +328,10 @@ msdos_probe (const PedDevice *dev) - return 1; - - probe_fail: -+ if (geom) -+ ped_geometry_destroy (geom); -+ if (fsgeom) -+ ped_geometry_destroy (fsgeom); - free (label); - return 0; - } --- -1.9.3 - diff --git a/0106-libparted-remove-old-partitions-first-before-adding-.patch b/0106-libparted-remove-old-partitions-first-before-adding-.patch deleted file mode 100644 index dd58299..0000000 --- a/0106-libparted-remove-old-partitions-first-before-adding-.patch +++ /dev/null @@ -1,151 +0,0 @@ -From 9e07d797b18609613c53ceb2dabbb5e69d961186 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 26 Apr 2014 20:52:25 -0400 -Subject: [PATCH 106/131] libparted: remove old partitions *first* before - adding new ones - -"libparted: avoid disturbing partitions" put the remove of the old -partition in second pass. If you simultaneously removed partitions 1 -and 2, and created a new partition #1 that overlapped the previous second -partition, the sync would fail because it would try to create the new, -larger partition #1 before removing the old partition #2. ---- - libparted/arch/linux.c | 43 ++++++++++++++-------------- - tests/Makefile.am | 1 + - tests/t1104-remove-and-add-partition.sh | 50 +++++++++++++++++++++++++++++++++ - 3 files changed, 72 insertions(+), 22 deletions(-) - create mode 100644 tests/t1104-remove-and-add-partition.sh - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 71f5034..ced06a3 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2855,23 +2855,8 @@ _disk_sync_part_table (PedDisk* disk) - && start == part->geom.start - && length == part->geom.length) - { -- ok[i - 1] = 1; -- continue; -- } -- } -- } -- for (i = 1; i <= lpn; i++) { -- PedPartition *part = ped_disk_get_partition (disk, i); -- if (part) { -- unsigned long long length; -- unsigned long long start; -- /* get start and length of existing partition */ -- if (get_partition_start_and_length(part, -- &start, &length) -- && start == part->geom.start -- && length == part->geom.length) { -- ok[i - 1] = 1; - /* partition is unchanged, so nothing to do */ -+ ok[i - 1] = 1; - continue; - } - } -@@ -2890,12 +2875,26 @@ _disk_sync_part_table (PedDisk* disk) - } while (n_sleep--); - if (!ok[i - 1] && errnums[i - 1] == ENXIO) - ok[i - 1] = 1; /* it already doesn't exist */ -- if (part && ok[i - 1]) { -- /* add the (possibly modified or new) partition */ -- if (!add_partition (disk, part)) { -- ok[i - 1] = 0; -- errnums[i - 1] = errno; -- } -+ } -+ for (i = 1; i <= lpn; i++) { -+ PedPartition *part = ped_disk_get_partition (disk, i); -+ if (!part) -+ continue; -+ unsigned long long length; -+ unsigned long long start; -+ /* get start and length of existing partition */ -+ if (get_partition_start_and_length(part, -+ &start, &length) -+ && start == part->geom.start -+ && length == part->geom.length) { -+ ok[i - 1] = 1; -+ /* partition is unchanged, so nothing to do */ -+ continue; -+ } -+ /* add the (possibly modified or new) partition */ -+ if (!add_partition (disk, part)) { -+ ok[i - 1] = 0; -+ errnums[i - 1] = errno; - } - } - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 9100a81..e064b8f 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -40,6 +40,7 @@ TESTS = \ - t0501-duplicate.sh \ - t1100-busy-label.sh \ - t1101-busy-partition.sh \ -+ t1104-remove-and-add-partition.sh \ - t1700-probe-fs.sh \ - t2200-dos-label-recog.sh \ - t2201-pc98-label-recog.sh \ -diff --git a/tests/t1104-remove-and-add-partition.sh b/tests/t1104-remove-and-add-partition.sh -new file mode 100644 -index 0000000..61cc392 ---- /dev/null -+++ b/tests/t1104-remove-and-add-partition.sh -@@ -0,0 +1,50 @@ -+#!/bin/sh -+# make sure that removing a higher numbered partition and adding a lower -+# one using that space at the same time works -+ -+# Copyright (C) 2014 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+path_prepend_ ../partprobe -+require_root_ -+ss=$sector_size_ -+ -+d1= f1= -+cleanup_fn_() -+{ -+ test -n "$d1" && losetup -d "$d1" -+ rm -f "$f1" -+} -+ -+f1=$(pwd)/1; d1=$(loop_setup_ "$f1") \ -+ || skip_ "is this partition mounted with 'nodev'?" -+ -+require_partitionable_loop_device_ $d1 -+ -+# create one big partition -+parted -s $d1 mklabel msdos mkpart primary ext2 1m 10m || fail=1 -+ -+# save this table -+dd if=$d1 of=saved count=1 || fail=1 -+ -+# create two small partitions -+parted -s $d1 mklabel msdos mkpart primary ext2 1m 5m mkpart primary ext2 5m 10m || fail=1 -+ -+# restore first table and make sure partprobe works -+dd if=saved of=$d1 || fail=1 -+partprobe $d1 || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0107-libparted-remove-all-old-partitions-even-if-new-labe.patch b/0107-libparted-remove-all-old-partitions-even-if-new-labe.patch deleted file mode 100644 index abc03bf..0000000 --- a/0107-libparted-remove-all-old-partitions-even-if-new-labe.patch +++ /dev/null @@ -1,63 +0,0 @@ -From dfdd8b0dd99b7fa990f40a3d3a225c5b3ef13c57 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 26 Apr 2014 21:16:15 -0400 -Subject: [PATCH 107/131] libparted: remove all old partitions, even if new - label allows less - -We were limiting partition sync operations to the lesser number allowed -by the device, or the label. This meant that when creating a new label -over an old label that had more partitions than the new one allows, the -higher partitions would not be removed. Use the greater of the two values -for the remove pass, and the lesser for the add. ---- - NEWS | 3 +++ - libparted/arch/linux.c | 11 +++++++++-- - 2 files changed, 12 insertions(+), 2 deletions(-) - -diff --git a/NEWS b/NEWS -index bc852e2..3dc39fd 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: remove all old partitions, even if new label does not allow -+ as many. -+ - libparted: fat and ntfs boot sectors were misdetected as dos - partition tables instead of being treated as a loop label. - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index ced06a3..4cbe49b 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2823,9 +2823,10 @@ _disk_sync_part_table (PedDisk* disk) - get_partition_start_and_length = _kernel_get_partition_start_and_length; - } - -- /* lpn = largest partition number. */ -+ /* lpn = largest partition number. -+ * for remove pass, use greater of device or label limit */ - if (ped_disk_get_max_supported_partition_count(disk, &lpn)) -- lpn = PED_MIN(lpn, part_range); -+ lpn = PED_MAX(lpn, part_range); - else - lpn = part_range; - -@@ -2876,6 +2877,12 @@ _disk_sync_part_table (PedDisk* disk) - if (!ok[i - 1] && errnums[i - 1] == ENXIO) - ok[i - 1] = 1; /* it already doesn't exist */ - } -+ /* lpn = largest partition number. -+ * for add pass, use lesser of device or label limit */ -+ if (ped_disk_get_max_supported_partition_count(disk, &lpn)) -+ lpn = PED_MIN(lpn, part_range); -+ else -+ lpn = part_range; - for (i = 1; i <= lpn; i++) { - PedPartition *part = ped_disk_get_partition (disk, i); - if (!part) --- -1.9.3 - diff --git a/0108-libparted-fix-loop-labels-to-not-vanish.patch b/0108-libparted-fix-loop-labels-to-not-vanish.patch deleted file mode 100644 index 7d78c6e..0000000 --- a/0108-libparted-fix-loop-labels-to-not-vanish.patch +++ /dev/null @@ -1,143 +0,0 @@ -From 32d637298717446a4edd3c8fbe637462fab4c000 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 26 Apr 2014 18:25:38 -0400 -Subject: [PATCH 108/131] libparted: fix loop labels to not vanish - -The loop label type was using the existence of a partition as a proxy for -a filesystem being detected, and loop_write() would try to write a loop -signature if there was no filesystem, and erase it if there was. Because -of this, creating a partition without writing a filesystem to it caused -loop_write to erase the loop label. - -There seems to be no reason to bother erasing the loop label if it is still -present along with a filesystem signature, so don't bother with this, and -actually check to see if a filesystem is detected in the partition rather -than using the existence of a partition to decide if writing the loop -signature is needed. Finally, since there is no way to preserve the -existence of a partition with no filesystem in it, have loop_read() always -create a partition, even if no filesystem is detected. ---- - NEWS | 6 ++++++ - libparted/labels/loop.c | 53 ++++++++++++++++++++++--------------------------- - 2 files changed, 30 insertions(+), 29 deletions(-) - -diff --git a/NEWS b/NEWS -index 3dc39fd..8ec11ab 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: fix loop labels to not vanish if you don't create -+ a filesystem, and to not return an error syncing when you do. -+ - libparted: remove all old partitions, even if new label does not allow - as many. - -@@ -116,6 +119,9 @@ GNU parted NEWS -*- outline -*- - - ** Changes in behavior - -+ When creating a loop label, it automatically comes with a partition -+ using the whole disk. -+ - parted -l no longer lists device-mapper devices other than - dmraid whole disks. - -diff --git a/libparted/labels/loop.c b/libparted/labels/loop.c -index ea8f007..8ebb1f4 100644 ---- a/libparted/labels/loop.c -+++ b/libparted/labels/loop.c -@@ -80,7 +80,23 @@ loop_alloc (const PedDevice* dev) - - if (dev->length < 256) - return NULL; -- return _ped_disk_alloc ((PedDevice*)dev, &loop_disk_type); -+ PedDisk *disk = _ped_disk_alloc ((PedDevice*)dev, &loop_disk_type); -+ PED_ASSERT (disk != NULL); -+ PedGeometry *geom = ped_geometry_new (dev, 0, dev->length); -+ PED_ASSERT (geom != NULL); -+ PedPartition *part = ped_partition_new (disk, PED_PARTITION_NORMAL, -+ NULL, geom->start, geom->end); -+ PED_ASSERT (part != NULL); -+ ped_geometry_destroy (geom); -+ PedConstraint *constraint_any = ped_constraint_any (dev); -+ if (!ped_disk_add_partition (disk, part, constraint_any)) -+ goto error; -+ ped_constraint_destroy (constraint_any); -+ return disk; -+ error: -+ ped_constraint_destroy (constraint_any); -+ ped_disk_destroy (disk); -+ return NULL; - } - - static PedDisk* -@@ -118,18 +134,12 @@ loop_read (PedDisk* disk) - - int found_sig = !strncmp (buf, LOOP_SIGNATURE, strlen (LOOP_SIGNATURE)); - free (buf); -- -- if (found_sig) { -- ped_constraint_destroy (constraint_any); -- return 1; -- } -- - geom = ped_geometry_new (dev, 0, dev->length); - if (!geom) - goto error; - - fs_type = ped_file_system_probe (geom); -- if (!fs_type) -+ if (!fs_type && !found_sig) - goto error_free_geom; - - part = ped_partition_new (disk, PED_PARTITION_NORMAL, -@@ -137,7 +147,6 @@ loop_read (PedDisk* disk) - ped_geometry_destroy (geom); - if (!part) - goto error; -- part->fs_type = fs_type; - - if (!ped_disk_add_partition (disk, part, constraint_any)) - goto error; -@@ -156,29 +165,15 @@ static int - loop_write (const PedDisk* disk) - { - size_t buflen = disk->dev->sector_size; -- char *buf = ped_malloc (buflen); -- if (buf == NULL) -- return 0; -- -- if (ped_disk_get_partition (disk, 1)) { -- if (!ped_device_read (disk->dev, buf, 0, 1)) { -- free (buf); -- return 0; -- } -- if (strncmp (buf, LOOP_SIGNATURE, strlen (LOOP_SIGNATURE)) != 0) { -- free (buf); -- return 1; -- } -- memset (buf, 0, strlen (LOOP_SIGNATURE)); -- return ped_device_write (disk->dev, buf, 0, 1); -- } -- -+ char *buf = alloca (buflen); -+ PedPartition *part = ped_disk_get_partition (disk, 1); -+ /* if there is already a filesystem on the disk, we don't need to write the signature */ -+ if (part && part->fs_type) -+ return 1; - memset (buf, 0, buflen); - strcpy (buf, LOOP_SIGNATURE); - -- int write_ok = ped_device_write (disk->dev, buf, 0, 1); -- free (buf); -- return write_ok; -+ return ped_device_write (disk->dev, buf, 0, 1); - } - #endif /* !DISCOVER_ONLY */ - --- -1.9.3 - diff --git a/0109-libparted-don-t-create-partition-on-loop-label.patch b/0109-libparted-don-t-create-partition-on-loop-label.patch deleted file mode 100644 index 14352fa..0000000 --- a/0109-libparted-don-t-create-partition-on-loop-label.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 7feb3b452c5ae57e75e16f8c00f46c9aa564a4cc Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 27 Apr 2014 11:15:47 -0400 -Subject: [PATCH 109/131] libparted: don't create partition on loop label - -The loop label represents an unpartitioned disk, but creates -a dummy partition to represent the whole disk. This dummy partition -was actually being loaded into the kernel. Don't do that. ---- - NEWS | 4 ++++ - libparted/arch/linux.c | 3 +++ - 2 files changed, 7 insertions(+) - -diff --git a/NEWS b/NEWS -index 8ec11ab..7d7edd8 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,10 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: The loop label represents an unpartitioned disk, but creates -+ a dummy partition to represent the whole disk. This dummy partition -+ was actually being loaded into the kernel. Don't do that. -+ - libparted: fix loop labels to not vanish if you don't create - a filesystem, and to not return an error syncing when you do. - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 4cbe49b..9ae6d64 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2883,6 +2883,9 @@ _disk_sync_part_table (PedDisk* disk) - lpn = PED_MIN(lpn, part_range); - else - lpn = part_range; -+ /* don't actually add partitions for loop */ -+ if (strcmp (disk->type->name, "loop") == 0) -+ lpn = 0; - for (i = 1; i <= lpn; i++) { - PedPartition *part = ped_disk_get_partition (disk, i); - if (!part) --- -1.9.3 - diff --git a/0110-partprobe-do-not-skip-loop-labels.patch b/0110-partprobe-do-not-skip-loop-labels.patch deleted file mode 100644 index 038d876..0000000 --- a/0110-partprobe-do-not-skip-loop-labels.patch +++ /dev/null @@ -1,44 +0,0 @@ -From ec0b631c43ced29a05557d911bbf57110d0b7ae3 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 26 Apr 2014 19:17:37 -0400 -Subject: [PATCH 110/131] partprobe: do not skip loop labels - -Partprobe was not syncing loop labels. This resulted it failing to remove -existing partitions when switching to a loop label. ---- - NEWS | 3 +++ - partprobe/partprobe.c | 4 +--- - 2 files changed, 4 insertions(+), 3 deletions(-) - -diff --git a/NEWS b/NEWS -index 7d7edd8..40ec2d0 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ partprobe: when called on a disk that has become a loop label, -+ remove any partitions left over from a previous label. -+ - libparted: The loop label represents an unpartitioned disk, but creates - a dummy partition to represent the whole disk. This dummy partition - was actually being loaded into the kernel. Don't do that. -diff --git a/partprobe/partprobe.c b/partprobe/partprobe.c -index 4da4fb7..8b744b5 100644 ---- a/partprobe/partprobe.c -+++ b/partprobe/partprobe.c -@@ -106,9 +106,7 @@ process_dev (PedDevice* dev) - PedDisk* disk; - - disk_type = ped_disk_probe (dev); -- if (disk_type && !strcmp (disk_type->name, "loop")) -- return 1; -- else if (!disk_type) { -+ if (!disk_type) { - /* Partition table not found, so create dummy, - empty one */ - disk_type = ped_disk_type_get("msdos"); --- -1.9.3 - diff --git a/0111-libparted-give-correct-partition-device-name-on-loop.patch b/0111-libparted-give-correct-partition-device-name-on-loop.patch deleted file mode 100644 index 801e0c3..0000000 --- a/0111-libparted-give-correct-partition-device-name-on-loop.patch +++ /dev/null @@ -1,80 +0,0 @@ -From 7cde99849ed321da2712248bc27c14a954d6b481 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sat, 26 Apr 2014 19:27:00 -0400 -Subject: [PATCH 111/131] libparted: give correct partition device name on loop - labels - -ped_partition_get_path() was returning "/dev/foo1" instead of -"/dev/foo" on loop labels. This caused gparted to run tools like mkfs on -a device node that did not actually exist. ---- - NEWS | 3 +++ - libparted/arch/linux.c | 10 ++++++++-- - 2 files changed, 11 insertions(+), 2 deletions(-) - -diff --git a/NEWS b/NEWS -index 40ec2d0..cfda7bf 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,9 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: ped_partition_get_path() was returning "/dev/foo1" instead -+ of "/dev/foo" for loop labels. -+ - partprobe: when called on a disk that has become a loop label, - remove any partitions left over from a previous label. - -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index 9ae6d64..f2e2abc 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -48,6 +48,7 @@ - #include "../architecture.h" - #include "dirname.h" - #include "xstrtol.h" -+#include "xalloc.h" - - #if ENABLE_NLS - # include -@@ -2356,6 +2357,9 @@ _device_get_part_path (PedDevice const *dev, int num) - static char* - linux_partition_get_path (const PedPartition* part) - { -+ /* loop label means use the whole disk */ -+ if (strcmp (part->disk->type->name, "loop") == 0) -+ return xstrdup (part->disk->dev->path); - return _device_get_part_path (part->disk->dev, part->num); - } - -@@ -2424,6 +2428,8 @@ linux_partition_is_busy (const PedPartition* part) - - PED_ASSERT (part != NULL); - -+ if (strcmp (part->disk->type->name, "loop") == 0) -+ return linux_is_busy (part->disk->dev); - if (_partition_is_mounted (part)) - return 1; - if (part->type == PED_PARTITION_EXTENDED) { -@@ -2546,7 +2552,7 @@ _sysfs_ull_entry_from_part(PedPartition const* part, const char *entry, - unsigned long long *val) - { - char path[128]; -- char *part_name = linux_partition_get_path(part); -+ char *part_name = _device_get_part_path (part->disk->dev, part->num); - if (!part_name) - return false; - -@@ -2581,7 +2587,7 @@ _kernel_get_partition_start_and_length(PedPartition const *part, - PED_ASSERT(start); - PED_ASSERT(length); - -- char *dev_name = linux_partition_get_path (part); -+ char *dev_name = _device_get_part_path (part->disk->dev, part->num); - if (!dev_name) - return false; - --- -1.9.3 - diff --git a/0112-libparted-don-t-trash-filesystem-when-writing-loop-l.patch b/0112-libparted-don-t-trash-filesystem-when-writing-loop-l.patch deleted file mode 100644 index 69ced9c..0000000 --- a/0112-libparted-don-t-trash-filesystem-when-writing-loop-l.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 1be70093eb937f34388e06ce3731e5f56f217950 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Fri, 2 May 2014 21:18:55 -0400 -Subject: [PATCH 112/131] libparted: don't trash filesystem when writing loop - label - -If you deleted the fake partition on a loop label, loop_write() would write -the loop signature to the device, zeroing out all other bytes in the first -sector. When the disk contained an ext[234] filesystem and was using 2k -sectors, this would trash the super block residing in the 1-2kb part of the -sector causing the disk to become unrecognized. Instead, read the existing -sector and only modify the first few bytes that contain the loop label. ---- - libparted/labels/loop.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/libparted/labels/loop.c b/libparted/labels/loop.c -index 8ebb1f4..98f9f23 100644 ---- a/libparted/labels/loop.c -+++ b/libparted/labels/loop.c -@@ -170,7 +170,8 @@ loop_write (const PedDisk* disk) - /* if there is already a filesystem on the disk, we don't need to write the signature */ - if (part && part->fs_type) - return 1; -- memset (buf, 0, buflen); -+ if (!ped_device_read (disk->dev, buf, 0, 1)) -+ return 0; - strcpy (buf, LOOP_SIGNATURE); - - return ped_device_write (disk->dev, buf, 0, 1); --- -1.9.3 - diff --git a/0113-tests-test-loop-labels.patch b/0113-tests-test-loop-labels.patch deleted file mode 100644 index 2140dee..0000000 --- a/0113-tests-test-loop-labels.patch +++ /dev/null @@ -1,137 +0,0 @@ -From 4feec152b1cf9cb2f33ebad86d3e2228a3862033 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Thu, 1 May 2014 22:46:31 -0400 -Subject: [PATCH 113/131] tests: test loop labels - -Verify previous fixes to loop labels. ---- - tests/Makefile.am | 1 + - tests/t1102-loop-label.sh | 104 ++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 105 insertions(+) - create mode 100644 tests/t1102-loop-label.sh - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index e064b8f..26226cf 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -40,6 +40,7 @@ TESTS = \ - t0501-duplicate.sh \ - t1100-busy-label.sh \ - t1101-busy-partition.sh \ -+ t1102-loop-label.sh \ - t1104-remove-and-add-partition.sh \ - t1700-probe-fs.sh \ - t2200-dos-label-recog.sh \ -diff --git a/tests/t1102-loop-label.sh b/tests/t1102-loop-label.sh -new file mode 100644 -index 0000000..f5701a3 ---- /dev/null -+++ b/tests/t1102-loop-label.sh -@@ -0,0 +1,104 @@ -+#!/bin/sh -+# make sure that loop labels work correctly -+# create an actual partition -+ -+# Copyright (C) 2013 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+path_prepend_ ../partprobe -+require_root_ -+require_scsi_debug_module_ -+ss=$sector_size_ -+ -+scsi_debug_setup_ sector_size=$ss dev_size_mb=90 > dev-name || -+ skip_ 'failed to create scsi_debug device' -+dev=$(cat dev-name) -+ -+mke2fs -F $dev -+parted -s "$dev" print > out 2>&1 || fail=1 -+cat < exp -+Model: Linux scsi_debug (scsi) -+Disk DEVICE: 94.4MB -+Sector size (logical/physical): ${ss}B/${ss}B -+Partition Table: loop -+Disk Flags: -+ -+Number Start End Size File system Flags -+ 1 0.00B 94.4MB 94.4MB ext2 -+ -+EOF -+mv out o2 && sed -e "s,$dev,DEVICE,;" o2 > out -+ -+compare exp out || fail=1 -+parted -s $dev rm 1 || fail=1 -+if [ -e ${dev}1 ]; then -+ echo "Partition should not exist on loop device" -+ fail=1 -+fi -+partprobe $dev || fail=1 -+if [ -e ${dev}1 ]; then -+ echo "Partition should not exist on loop device" -+ fail=1 -+fi -+ -+mount_point="`pwd`/mnt" -+ -+# Be sure to unmount upon interrupt, failure, etc. -+cleanup_fn_() { umount "$mount_point" > /dev/null 2>&1; } -+ -+# create mount point dir. and mount the just-created partition on it -+mkdir $mount_point || fail=1 -+mount -t ext2 "${dev}" $mount_point || fail=1 -+ -+# now that a partition is mounted, mklabel attempt must fail -+parted -s "$dev" mklabel msdos > out 2>&1; test $? = 1 || fail=1 -+ -+# create expected output file -+echo "Error: Partition(s) on $dev are being used." > exp -+compare exp out || fail=1 -+ -+# make sure partition busy check works ( mklabel checks whole disk ) -+parted -s "$dev" rm 1 > out 2>&1; test $? = 1 || fail=1 -+# create expected output file -+echo "Error: Partition $dev is being used. You must unmount it before you modify \ -+it with Parted." > exp -+compare exp out || fail=1 -+ -+umount "$mount_point" -+ -+# make sure partprobe cleans up stale partition devices -+parted -s $dev mklabel msdos mkpart primary ext2 0% 100% || fail=1 -+if [ ! -e ${dev}1 ]; then -+ echo "Partition doesn't exist on loop device" -+ fail=1 -+fi -+ -+mke2fs -F $dev -+partprobe $dev || fail=1 -+if [ -e ${dev}1 ]; then -+ echo "Partition should not exist on loop device" -+ fail=1 -+fi -+ -+# make sure new loop label removes old partitions > 1 -+parted -s $dev mklabel msdos mkpart primary ext2 0% 50% mkpart primary ext2 50% 100% || fail=1 -+parted -s $dev mklabel loop || fail=1 -+if [ -e ${dev}2 ]; then -+ echo "Partition 2 not removed" -+ fail=1 -+fi -+ -+Exit $fail --- -1.9.3 - diff --git a/0114-libparted-mac-support-sector-size-512-correctly.patch b/0114-libparted-mac-support-sector-size-512-correctly.patch deleted file mode 100644 index 8016ca9..0000000 --- a/0114-libparted-mac-support-sector-size-512-correctly.patch +++ /dev/null @@ -1,242 +0,0 @@ -From 70e069b13e62e44e7bc4e594723c48ec174500f9 Mon Sep 17 00:00:00 2001 -From: Sergei Antonov -Date: Sat, 1 Mar 2014 21:43:31 +0100 -Subject: [PATCH 114/125] libparted: mac: support sector size > 512 correctly - -This patch fixes several problems found when trying to do Apple -Partition Map on a 4K-sector iPod. The problems happened because of -unneeded conversion between physical sectors and 512-byte units. -For devices with sector 512 the conversion did no harm, for others it did. - -List of problems (all are gone with the patch): - -* Partition in OS X, connect to Linux, run "parted print". - "Error: Can't have a partition outside the disk!" is shown. - Every partition is displayed 8 times (4k/512) bigger its real size. - -* Exec "mktable mac", connect to OS X. - The drive's partitioning scheme is not recognized. - -* mkpart creates partitions 8 times (4k/512) smaller than requested. - -Signed-off-by: Sergei Antonov ---- - NEWS | 2 ++ - libparted/labels/mac.c | 59 ++++++++++++++++++-------------------------------- - 2 files changed, 23 insertions(+), 38 deletions(-) - -diff --git a/NEWS b/NEWS -index cfda7bf..986da8f 100644 ---- a/NEWS -+++ b/NEWS -@@ -29,6 +29,8 @@ GNU parted NEWS -*- outline -*- - - ** Bug Fixes - -+ libparted: fix mac partition tables on > 512 byte sector sizes -+ - libparted: ped_partition_get_path() was returning "/dev/foo1" instead - of "/dev/foo" for loop labels. - -diff --git a/libparted/labels/mac.c b/libparted/labels/mac.c -index f26f8e5..baf2a9f 100644 ---- a/libparted/labels/mac.c -+++ b/libparted/labels/mac.c -@@ -290,7 +290,7 @@ mac_alloc (const PedDevice* dev) - if (!mac_disk_data) - goto error_free_disk; - disk->disk_specific = mac_disk_data; -- mac_disk_data->ghost_size = disk->dev->sector_size / 512; -+ mac_disk_data->ghost_size = 1; - mac_disk_data->active_part_entry_count = 0; - mac_disk_data->free_part_entry_count = 1; - mac_disk_data->last_part_entry_num = 1; -@@ -410,13 +410,12 @@ static int _GL_ATTRIBUTE_PURE - _rawpart_has_driver (const MacRawPartition* raw_part, MacDiskData* mac_disk_data) - { - MacDeviceDriver *driverlist; -- uint16_t i, bsz; -+ uint16_t i; - uint32_t driver_bs, driver_be, part_be; - - driverlist = &mac_disk_data->driverlist[0]; -- bsz = mac_disk_data->block_size / 512; - for (i = 0; i < mac_disk_data->driver_count; i++) { -- driver_bs = driverlist->block * bsz; -+ driver_bs = driverlist->block; - driver_be = driver_bs + driverlist->size; - part_be = raw_part->start_block + raw_part->block_count; - if (driver_bs >= raw_part->start_block && driver_be <= part_be) -@@ -497,7 +496,6 @@ _rawpart_analyse (MacRawPartition* raw_part, PedDisk* disk, int num) - MacDiskData* mac_disk_data; - PedPartition* part; - MacPartitionData* mac_part_data; -- PedSector block_size; - PedSector start, length; - - if (!_rawpart_check_signature (raw_part)) { -@@ -514,10 +512,9 @@ _rawpart_analyse (MacRawPartition* raw_part, PedDisk* disk, int num) - } - - mac_disk_data = (MacDiskData*) disk->disk_specific; -- block_size = disk->dev->sector_size / 512; - -- start = PED_BE32_TO_CPU (raw_part->start_block) * block_size; -- length = PED_BE32_TO_CPU (raw_part->block_count) * block_size; -+ start = PED_BE32_TO_CPU (raw_part->start_block); -+ length = PED_BE32_TO_CPU (raw_part->block_count); - if (length == 0) { - #ifndef DISCOVER_ONLY - ped_exception_throw ( -@@ -560,7 +557,7 @@ _rawpart_analyse (MacRawPartition* raw_part, PedDisk* disk, int num) - } - #endif /* !DISCOVER_ONLY */ - mac_part_data->data_region_length -- = PED_BE32_TO_CPU (raw_part->data_count) * block_size; -+ = 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 -@@ -577,7 +574,7 @@ _rawpart_analyse (MacRawPartition* raw_part, PedDisk* disk, int num) - } - #endif - mac_part_data->boot_region_length -- = PED_BE32_TO_CPU (raw_part->boot_count) * block_size; -+ = PED_BE32_TO_CPU (raw_part->boot_count); - - #ifndef DISCOVER_ONLY - if (mac_part_data->has_driver) { -@@ -629,12 +626,11 @@ static int - _rawpart_get_partmap_size (MacRawPartition* raw_part, PedDisk* disk) - { - MacDiskData* mac_disk_data = disk->disk_specific; -- PedSector sector_size = disk->dev->sector_size / 512; - PedSector part_map_start; - PedSector part_map_end; - - part_map_start = mac_disk_data->ghost_size; -- part_map_end = sector_size * PED_BE32_TO_CPU (raw_part->map_count); -+ part_map_end = PED_BE32_TO_CPU (raw_part->map_count); - - return part_map_end - part_map_start + 1; - } -@@ -881,14 +877,13 @@ static void - _update_driver_count (MacRawPartition* part_map_entry, - MacDiskData *mac_driverdata, const MacDiskData* mac_disk_data) - { -- uint16_t i, count_orig, count_cur, bsz; -+ uint16_t i, count_orig, count_cur; - uint32_t driver_bs, driver_be, part_be; - -- bsz = mac_disk_data->block_size / 512; - count_cur = mac_driverdata->driver_count; - count_orig = mac_disk_data->driver_count; - for (i = 0; i < count_orig; i++) { -- driver_bs = mac_disk_data->driverlist[i].block * bsz; -+ driver_bs = mac_disk_data->driverlist[i].block; - driver_be = driver_bs + mac_disk_data->driverlist[i].size; - part_be = part_map_entry->start_block + part_map_entry->block_count; - if (driver_bs >= part_map_entry->start_block -@@ -921,7 +916,6 @@ _generate_raw_part (PedDisk* disk, PedPartition* part, - { - MacDiskData* mac_disk_data; - MacPartitionData* mac_part_data; -- PedSector block_size = disk->dev->sector_size / 512; - - PED_ASSERT (part->num > 0); - -@@ -934,10 +928,8 @@ _generate_raw_part (PedDisk* disk, PedPartition* part, - part_map_entry->signature = PED_CPU_TO_BE16 (MAC_PARTITION_MAGIC_2); - part_map_entry->map_count - = PED_CPU_TO_BE32 (mac_disk_data->last_part_entry_num); -- part_map_entry->start_block -- = PED_CPU_TO_BE32 (part->geom.start / block_size); -- part_map_entry->block_count -- = PED_CPU_TO_BE32 (part->geom.length / block_size); -+ part_map_entry->start_block = PED_CPU_TO_BE32 (part->geom.start); -+ part_map_entry->block_count = PED_CPU_TO_BE32 (part->geom.length); - strcpy (part_map_entry->name, mac_part_data->volume_name); - strcpy (part_map_entry->type, mac_part_data->system_name); - -@@ -949,9 +941,9 @@ _generate_raw_part (PedDisk* disk, PedPartition* part, - } else - mac_part_data->data_region_length = part->geom.length; - part_map_entry->data_count = PED_CPU_TO_BE32 ( -- mac_part_data->data_region_length / block_size); -+ mac_part_data->data_region_length); - part_map_entry->boot_count = PED_CPU_TO_BE32 ( -- mac_part_data->boot_region_length / block_size); -+ mac_part_data->boot_region_length); - part_map_entry->status = PED_CPU_TO_BE32 (mac_part_data->status); - part_map_entry->driver_sig - = PED_CPU_TO_BE32 (mac_part_data->driver_sig); -@@ -979,7 +971,6 @@ _generate_raw_freespace_part (PedDisk* disk, PedGeometry* geom, int num, - MacRawPartition* part_map) - { - MacDiskData* mac_disk_data = disk->disk_specific; -- PedSector block_size = disk->dev->sector_size / 512; - - PED_ASSERT (num > 0); - -@@ -988,10 +979,8 @@ _generate_raw_freespace_part (PedDisk* disk, PedGeometry* geom, int num, - part_map_entry->signature = PED_CPU_TO_BE16 (MAC_PARTITION_MAGIC_2); - part_map_entry->map_count - = PED_CPU_TO_BE32 (mac_disk_data->last_part_entry_num); -- part_map_entry->start_block -- = PED_CPU_TO_BE32 (geom->start / block_size); -- part_map_entry->block_count -- = PED_CPU_TO_BE32 (geom->length / block_size); -+ part_map_entry->start_block = PED_CPU_TO_BE32 (geom->start); -+ part_map_entry->block_count = PED_CPU_TO_BE32 (geom->length); - strcpy (part_map_entry->name, "Extra"); - strcpy (part_map_entry->type, "Apple_Free"); - -@@ -1051,8 +1040,7 @@ write_block_zero (PedDisk* disk, MacDiskData* mac_driverdata) - - raw_disk->signature = PED_CPU_TO_BE16 (MAC_DISK_MAGIC); - raw_disk->block_size = PED_CPU_TO_BE16 (dev->sector_size); -- raw_disk->block_count -- = PED_CPU_TO_BE32 (dev->length / (dev->sector_size / 512)); -+ raw_disk->block_count = PED_CPU_TO_BE32 (dev->length); - - raw_disk->driver_count = mac_driverdata->driver_count; - memcpy(&raw_disk->driverlist[0], &mac_driverdata->driverlist[0], -@@ -1395,9 +1383,7 @@ mac_partition_get_name (const PedPartition* part) - static PedAlignment* - mac_get_partition_alignment(const PedDisk *disk) - { -- PedSector sector_size = disk->dev->sector_size / 512; -- -- return ped_alignment_new(0, sector_size); -+ return ped_alignment_new(0, 1); - } - - static PedConstraint* -@@ -1406,13 +1392,10 @@ _primary_constraint (PedDisk* disk) - PedAlignment start_align; - PedAlignment end_align; - PedGeometry max_geom; -- PedSector sector_size; -- -- sector_size = disk->dev->sector_size / 512; - -- if (!ped_alignment_init (&start_align, 0, sector_size)) -+ if (!ped_alignment_init (&start_align, 0, 1)) - return NULL; -- if (!ped_alignment_init (&end_align, -1, sector_size)) -+ if (!ped_alignment_init (&end_align, -1, 1)) - return NULL; - if (!ped_geometry_init (&max_geom, disk->dev, 1, disk->dev->length - 1)) - return NULL; -@@ -1548,7 +1531,7 @@ mac_alloc_metadata (PedDisk* disk) - PED_ASSERT (disk->disk_specific != NULL); - PED_ASSERT (disk->dev != NULL); - -- if (!add_metadata_part (disk, 0, disk->dev->sector_size / 512 - 1)) -+ if (!add_metadata_part (disk, 0, 0)) - return 0; - - /* hack: this seems to be a good place, to update the partition map --- -1.9.3 - diff --git a/0115-gnulib-update-submodule-to-latest.patch b/0115-gnulib-update-submodule-to-latest.patch deleted file mode 100644 index be71865..0000000 --- a/0115-gnulib-update-submodule-to-latest.patch +++ /dev/null @@ -1,54 +0,0 @@ -From d21a2f56602e165d9da4999b32da5c236d767289 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 25 May 2014 15:28:56 -0700 -Subject: [PATCH 115/125] gnulib: update submodule to latest - -* gnulib: Update module to latest. -* bootstrap: Update from gnulib. ---- - bootstrap | 12 ++++++++++-- - gnulib | 2 +- - 2 files changed, 11 insertions(+), 3 deletions(-) - -diff --git a/bootstrap b/bootstrap -index e31d17d..ce90bc4 100755 ---- a/bootstrap -+++ b/bootstrap -@@ -1,10 +1,10 @@ - #! /bin/sh - # Print a version string. --scriptversion=2013-08-15.22; # UTC -+scriptversion=2013-12-05.23; # UTC - - # Bootstrap this package from checked-out sources. - --# Copyright (C) 2003-2013 Free Software Foundation, Inc. -+# Copyright (C) 2003-2014 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -@@ -551,6 +551,14 @@ if ! printf "$buildreq" | check_versions; then - fi - fi - -+# Warn the user if autom4te appears to be broken; this causes known -+# issues with at least gettext 0.18.3. -+probe=$(echo 'm4_quote([hi])' | autom4te -l M4sugar -t 'm4_quote:$%' -) -+if test "x$probe" != xhi; then -+ warn_ "WARNING: your autom4te wrapper eats stdin;" -+ warn_ "if bootstrap fails, consider upgrading your autotools" -+fi -+ - echo "$0: Bootstrapping from checked-out $package sources..." - - # See if we can use gnulib's git-merge-changelog merge driver. -diff --git a/gnulib b/gnulib -index 164ebfe..98ca2c0 160000 ---- a/gnulib -+++ b/gnulib -@@ -1 +1 @@ --Subproject commit 164ebfe612d8460c15d7acf1927faef6943571b6 -+Subproject commit 98ca2c063cfe019b673fd0ce81448c919e9c989c --- -1.9.3 - diff --git a/0116-maint-remove-doubled-word-s-on-on-on.patch b/0116-maint-remove-doubled-word-s-on-on-on.patch deleted file mode 100644 index 6d2710a..0000000 --- a/0116-maint-remove-doubled-word-s-on-on-on.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 2ca0dbe933639299187473041cb7fc5deb17d097 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 25 May 2014 20:35:27 -0700 -Subject: [PATCH 116/125] maint: remove doubled word: s/on on/on/ - -* NEWS: Remove doubled-word detected by "make syntax-check". ---- - NEWS | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/NEWS b/NEWS -index 986da8f..3d237fa 100644 ---- a/NEWS -+++ b/NEWS -@@ -52,7 +52,7 @@ GNU parted NEWS -*- outline -*- - - libparted: previously if you chose to ignore the warning about - the gpt thinking the disk was smaller than it appears to be on -- on disk, subsequent warnings on other disks would be suppressed. -+ disk, subsequent warnings on other disks would be suppressed. - Now parted will warn once per disk. - - Fix filesystem detection on non 512 byte sector sizes --- -1.9.3 - diff --git a/0117-maint-run-make-update-copyright.patch b/0117-maint-run-make-update-copyright.patch deleted file mode 100644 index bd1f771..0000000 --- a/0117-maint-run-make-update-copyright.patch +++ /dev/null @@ -1,2965 +0,0 @@ -From b71fb875187e54853595d4fda0cba606b4491c2c Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 25 May 2014 21:31:53 -0700 -Subject: [PATCH 117/125] maint: run "make update-copyright" - ---- - HACKING | 2 +- - NEWS | 2 +- - README-hacking | 2 +- - bootstrap.conf | 2 +- - cfg.mk | 2 +- - configure.ac | 2 +- - debug/test/HOWTO | 2 +- - doc/gendocs.sh | 2 +- - doc/parted-pt_BR.texi | 2 +- - include/parted/constraint.in.h | 2 +- - include/parted/crc32.in.h | 2 +- - include/parted/debug.in.h | 2 +- - include/parted/device.in.h | 2 +- - include/parted/disk.in.h | 2 +- - include/parted/endian.in.h | 2 +- - include/parted/exception.in.h | 2 +- - include/parted/filesys.in.h | 2 +- - include/parted/geom.in.h | 2 +- - include/parted/natmath.in.h | 2 +- - include/parted/parted.in.h | 2 +- - include/parted/timer.in.h | 2 +- - include/parted/unit.in.h | 2 +- - libparted/Makefile.am | 2 +- - libparted/arch/beos.c | 2 +- - libparted/arch/gnu.c | 2 +- - libparted/arch/linux.c | 2 +- - libparted/arch/linux.h | 2 +- - libparted/architecture.c | 2 +- - libparted/architecture.h | 2 +- - libparted/cs/constraint.c | 2 +- - libparted/cs/geom.c | 2 +- - libparted/cs/natmath.c | 2 +- - libparted/debug.c | 2 +- - libparted/disk.c | 2 +- - libparted/exception.c | 2 +- - libparted/filesys.c | 2 +- - libparted/fs/Makefile.am | 2 +- - libparted/fs/amiga/a-interface.c | 2 +- - libparted/fs/amiga/affs.c | 2 +- - libparted/fs/amiga/affs.h | 2 +- - libparted/fs/amiga/amiga.c | 2 +- - libparted/fs/amiga/amiga.h | 2 +- - libparted/fs/amiga/apfs.c | 2 +- - libparted/fs/amiga/apfs.h | 2 +- - libparted/fs/amiga/asfs.c | 2 +- - libparted/fs/amiga/asfs.h | 2 +- - libparted/fs/btrfs/btrfs.c | 2 +- - libparted/fs/ext2/ext2.h | 2 +- - libparted/fs/ext2/ext2_fs.h | 2 +- - libparted/fs/ext2/interface.c | 2 +- - libparted/fs/fat/bootsector.c | 2 +- - libparted/fs/fat/bootsector.h | 2 +- - libparted/fs/fat/count.h | 2 +- - libparted/fs/fat/fat.c | 2 +- - libparted/fs/fat/fat.h | 2 +- - libparted/fs/hfs/hfs.c | 2 +- - libparted/fs/hfs/hfs.h | 2 +- - libparted/fs/hfs/probe.c | 2 +- - libparted/fs/hfs/probe.h | 2 +- - libparted/fs/jfs/jfs.c | 2 +- - libparted/fs/linux_swap/linux_swap.c | 2 +- - libparted/fs/nilfs2/nilfs2.c | 2 +- - libparted/fs/ntfs/ntfs.c | 2 +- - libparted/fs/r/fat/bootsector.c | 2 +- - libparted/fs/r/fat/bootsector.h | 2 +- - libparted/fs/r/fat/calc.c | 2 +- - libparted/fs/r/fat/calc.h | 2 +- - libparted/fs/r/fat/clstdup.c | 2 +- - libparted/fs/r/fat/clstdup.h | 2 +- - libparted/fs/r/fat/context.c | 2 +- - libparted/fs/r/fat/context.h | 2 +- - libparted/fs/r/fat/count.c | 2 +- - libparted/fs/r/fat/count.h | 2 +- - libparted/fs/r/fat/fat.c | 2 +- - libparted/fs/r/fat/fat.h | 2 +- - libparted/fs/r/fat/fatio.c | 2 +- - libparted/fs/r/fat/fatio.h | 2 +- - libparted/fs/r/fat/resize.c | 2 +- - libparted/fs/r/fat/table.c | 2 +- - libparted/fs/r/fat/table.h | 2 +- - libparted/fs/r/fat/traverse.c | 2 +- - libparted/fs/r/fat/traverse.h | 2 +- - libparted/fs/r/filesys.c | 2 +- - libparted/fs/r/hfs/advfs.c | 2 +- - libparted/fs/r/hfs/advfs.h | 2 +- - libparted/fs/r/hfs/advfs_plus.c | 2 +- - libparted/fs/r/hfs/advfs_plus.h | 2 +- - libparted/fs/r/hfs/cache.c | 2 +- - libparted/fs/r/hfs/cache.h | 2 +- - libparted/fs/r/hfs/file.c | 2 +- - libparted/fs/r/hfs/file.h | 2 +- - libparted/fs/r/hfs/file_plus.c | 2 +- - libparted/fs/r/hfs/file_plus.h | 2 +- - libparted/fs/r/hfs/hfs.c | 2 +- - libparted/fs/r/hfs/hfs.h | 2 +- - libparted/fs/r/hfs/journal.c | 2 +- - libparted/fs/r/hfs/journal.h | 2 +- - libparted/fs/r/hfs/probe.c | 2 +- - libparted/fs/r/hfs/probe.h | 2 +- - libparted/fs/r/hfs/reloc.c | 2 +- - libparted/fs/r/hfs/reloc.h | 2 +- - libparted/fs/r/hfs/reloc_plus.c | 2 +- - libparted/fs/r/hfs/reloc_plus.h | 2 +- - libparted/fs/reiserfs/reiserfs.c | 2 +- - libparted/fs/reiserfs/reiserfs.h | 2 +- - libparted/fs/ufs/ufs.c | 2 +- - libparted/fs/xfs/xfs.c | 2 +- - libparted/labels/Makefile.am | 2 +- - libparted/labels/aix.c | 2 +- - libparted/labels/bsd.c | 2 +- - libparted/labels/dasd.c | 2 +- - libparted/labels/dos.c | 2 +- - libparted/labels/dvh.c | 2 +- - libparted/labels/loop.c | 2 +- - libparted/labels/mac.c | 2 +- - libparted/labels/misc.h | 2 +- - libparted/labels/pc98.c | 2 +- - libparted/labels/pt-tools.c | 2 +- - libparted/labels/pt-tools.h | 2 +- - libparted/labels/rdb.c | 2 +- - libparted/labels/sun.c | 2 +- - libparted/libparted.c | 2 +- - libparted/mbr.s | 2 +- - libparted/tests/Makefile.am | 2 +- - libparted/tests/t1000-label.sh | 2 +- - libparted/tests/t2000-disk.sh | 2 +- - libparted/tests/t2100-zerolen.sh | 2 +- - libparted/tests/t3000-symlink.sh | 2 +- - libparted/timer.c | 2 +- - libparted/unit.c | 2 +- - m4/o-direct.m4 | 2 +- - parted/command.c | 2 +- - parted/command.h | 2 +- - parted/parted.c | 2 +- - parted/strlist.c | 2 +- - parted/strlist.h | 2 +- - parted/table.c | 2 +- - parted/table.h | 2 +- - parted/ui.c | 2 +- - parted/ui.h | 2 +- - partprobe/partprobe.c | 2 +- - po/POTFILES.in | 2 +- - scripts/extract_symvers | 2 +- - scripts/update-po | 2 +- - tests/help-version.sh | 2 +- - tests/init.sh | 2 +- - tests/t0000-basic.sh | 2 +- - tests/t0001-tiny.sh | 2 +- - tests/t0010-script-no-ctrl-chars.sh | 2 +- - tests/t0100-print.sh | 2 +- - tests/t0101-print-empty.sh | 2 +- - tests/t0200-gpt.sh | 2 +- - tests/t0201-gpt.sh | 2 +- - tests/t0202-gpt-pmbr.sh | 2 +- - tests/t0203-gpt-create-on-min-sized-device.sh | 2 +- - tests/t0203-gpt-shortened-device-primary-valid.sh | 2 +- - tests/t0203-gpt-tiny-device-abort.sh | 2 +- - tests/t0205-gpt-list-clobbers-pmbr.sh | 2 +- - tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh | 2 +- - tests/t0207-IEC-binary-notation.sh | 2 +- - tests/t0208-mkpart-end-in-IEC.sh | 2 +- - tests/t0209-gpt-pmbr_boot.sh | 2 +- - tests/t0210-gpt-resized-partition-entry-array.sh | 2 +- - tests/t0211-gpt-rewrite-header.sh | 2 +- - tests/t0212-gpt-many-partitions.sh | 2 +- - tests/t0220-gpt-msftres.sh | 2 +- - tests/t0250-gpt.sh | 2 +- - tests/t0251-gpt-unicode.sh | 2 +- - tests/t0280-gpt-corrupt.sh | 2 +- - tests/t0281-gpt-grow.sh | 2 +- - tests/t0282-gpt-move-backup.sh | 2 +- - tests/t0283-overlap-partitions.sh | 2 +- - tests/t0300-dos-on-gpt.sh | 2 +- - tests/t0301-overwrite-gpt-pmbr.sh | 2 +- - tests/t0350-mac-PT-increases-sector-size.sh | 2 +- - tests/t0400-loop-clobber-infloop.sh | 2 +- - tests/t0500-dup-clobber.sh | 2 +- - tests/t0501-duplicate.sh | 2 +- - tests/t1100-busy-label.sh | 2 +- - tests/t1101-busy-partition.sh | 2 +- - tests/t1102-loop-label.sh | 2 +- - tests/t1700-probe-fs.sh | 2 +- - tests/t2200-dos-label-recog.sh | 2 +- - tests/t2201-pc98-label-recog.sh | 2 +- - tests/t2300-dos-label-extended-bootcode.sh | 2 +- - tests/t2310-dos-extended-2-sector-min-offset.sh | 2 +- - tests/t2400-dos-hfs-partition-type.sh | 2 +- - tests/t2500-probe-corrupt-hfs.sh | 2 +- - tests/t3000-resize-fs.sh | 2 +- - tests/t3200-type-change.sh | 2 +- - tests/t3300-palo-prep.sh | 2 +- - tests/t3310-flags.sh | 2 +- - tests/t3400-whole-disk-FAT-partition.sh | 2 +- - tests/t4000-sun-raid-type.sh | 2 +- - tests/t4001-sun-vtoc.sh | 2 +- - tests/t4100-dvh-partition-limits.sh | 2 +- - tests/t4100-msdos-partition-limits.sh | 2 +- - tests/t4100-msdos-starting-sector.sh | 2 +- - tests/t4200-partprobe.sh | 2 +- - tests/t4300-nilfs2-tiny.sh | 2 +- - tests/t5000-tags.sh | 2 +- - tests/t6000-dm.sh | 2 +- - tests/t6001-psep.sh | 2 +- - tests/t6002-dm-busy.sh | 2 +- - tests/t6003-dm-hide.sh | 2 +- - tests/t6004-dm-many-partitions.sh | 2 +- - tests/t6005-dm-uuid.sh | 2 +- - tests/t6100-mdraid-partitions.sh | 2 +- - tests/t7000-scripting.sh | 2 +- - tests/t8000-loop.sh | 2 +- - tests/t8001-loop-blkpg.sh | 2 +- - tests/t9010-big-sector.sh | 2 +- - tests/t9020-alignment.sh | 2 +- - tests/t9021-maxima.sh | 2 +- - tests/t9022-one-unit-snap.sh | 2 +- - tests/t9023-value-lt-one.sh | 2 +- - tests/t9030-align-check.sh | 2 +- - tests/t9040-many-partitions.sh | 2 +- - tests/t9041-undetected-in-use-16th-partition.sh | 2 +- - tests/t9042-dos-partition-limit.sh | 2 +- - tests/t9050-partition-table-types.sh | 2 +- - 221 files changed, 221 insertions(+), 221 deletions(-) - -diff --git a/HACKING b/HACKING -index b8e501c..e9aa52e 100644 ---- a/HACKING -+++ b/HACKING -@@ -581,7 +581,7 @@ Then just open the index.html file (in the generated lcov-html directory) - in your favorite web browser. - - ======================================================================== --Copyright (C) 2009-2013 Free Software Foundation, Inc. -+Copyright (C) 2009-2014 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -diff --git a/NEWS b/NEWS -index 3d237fa..3de5dde 100644 ---- a/NEWS -+++ b/NEWS -@@ -853,7 +853,7 @@ GNU parted NEWS -*- outline -*- - - ======================================================================== - --Copyright (C) 2001-2013 Free Software Foundation, Inc. -+Copyright (C) 2001-2014 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -diff --git a/README-hacking b/README-hacking -index 5aa9ef3..97ce115 100644 ---- a/README-hacking -+++ b/README-hacking -@@ -69,7 +69,7 @@ Enjoy! - - ----- - --Copyright (C) 2002-2013 Free Software Foundation, Inc. -+Copyright (C) 2002-2014 Free Software Foundation, Inc. - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/bootstrap.conf b/bootstrap.conf -index f6f4ff2..873fde1 100644 ---- a/bootstrap.conf -+++ b/bootstrap.conf -@@ -1,6 +1,6 @@ - # Bootstrap configuration. - --# Copyright (C) 2006-2013 Free Software Foundation, Inc. -+# Copyright (C) 2006-2014 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/cfg.mk b/cfg.mk -index 2590a38..ade72d7 100644 ---- a/cfg.mk -+++ b/cfg.mk -@@ -1,5 +1,5 @@ - # Customize maint.mk -*- makefile -*- --# Copyright (C) 2003-2013 Free Software Foundation, Inc. -+# Copyright (C) 2003-2014 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/configure.ac b/configure.ac -index b04eb3f..436d0e2 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -1,5 +1,5 @@ - dnl GNU Parted - a library and front end for manipulation hard disk partitions --dnl Copyright (C) 1998-2002, 2005-2013 Free Software Foundation, Inc. -+dnl Copyright (C) 1998-2002, 2005-2014 Free Software Foundation, Inc. - dnl - dnl This file may be modified and/or distributed without restriction. - -diff --git a/debug/test/HOWTO b/debug/test/HOWTO -index f611e4f..3402766 100644 ---- a/debug/test/HOWTO -+++ b/debug/test/HOWTO -@@ -4,7 +4,7 @@ - - by Andrew Clausen - -- Copyright (C) 2002, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2002, 2009-2014 Free Software Foundation, Inc. - This document may be distributed and/or modified - without restriction - -diff --git a/doc/gendocs.sh b/doc/gendocs.sh -index 1d2f9be..0df9da8 100755 ---- a/doc/gendocs.sh -+++ b/doc/gendocs.sh -@@ -3,7 +3,7 @@ - # mentioned in maintain.texi. See the help message below for usage details. - # $Id: gendocs.sh,v 1.16 2005/05/15 00:00:08 karl Exp $ - # --# Copyright (C) 2003-2007, 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2003-2007, 2009-2014 Free Software Foundation, Inc. - # - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/doc/parted-pt_BR.texi b/doc/parted-pt_BR.texi -index 8858ab5..4297c70 100644 ---- a/doc/parted-pt_BR.texi -+++ b/doc/parted-pt_BR.texi -@@ -22,7 +22,7 @@ - This file documents the use of GNU Parted, a program for creating, - resising, checking and copy partitions, and file systems on them. - --Copyright 1999-2002, 2009-2013 Free Software Foundation, Inc. -+Copyright 1999-2002, 2009-2014 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -diff --git a/include/parted/constraint.in.h b/include/parted/constraint.in.h -index 4f7855b..4b511a5 100644 ---- a/include/parted/constraint.in.h -+++ b/include/parted/constraint.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/crc32.in.h b/include/parted/crc32.in.h -index af8de0a..62a8a99 100644 ---- a/include/parted/crc32.in.h -+++ b/include/parted/crc32.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - crc32.h - -diff --git a/include/parted/debug.in.h b/include/parted/debug.in.h -index 07c1257..4632886 100644 ---- a/include/parted/debug.in.h -+++ b/include/parted/debug.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2000, 2002, 2007, 2009-2013 Free Software Foundation, -+ Copyright (C) 1998-2000, 2002, 2007, 2009-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/device.in.h b/include/parted/device.in.h -index 7c06a66..82d4104 100644 ---- a/include/parted/device.in.h -+++ b/include/parted/device.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2001, 2005, 2007-2008, 2011-2013 Free Software -+ Copyright (C) 1998-2001, 2005, 2007-2008, 2011-2014 Free Software - Foundation, Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/disk.in.h b/include/parted/disk.in.h -index d144e21..58d49f0 100644 ---- a/include/parted/disk.in.h -+++ b/include/parted/disk.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2002, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2002, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/endian.in.h b/include/parted/endian.in.h -index 381059f..2b0e47b 100644 ---- a/include/parted/endian.in.h -+++ b/include/parted/endian.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2002, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2002, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/exception.in.h b/include/parted/exception.in.h -index ef96280..574d915 100644 ---- a/include/parted/exception.in.h -+++ b/include/parted/exception.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/filesys.in.h b/include/parted/filesys.in.h -index b42d7c9..a9e23de 100644 ---- a/include/parted/filesys.in.h -+++ b/include/parted/filesys.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2006-2007, 2009-2013 Free Software Foundation, -+ Copyright (C) 1999-2001, 2006-2007, 2009-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/geom.in.h b/include/parted/geom.in.h -index 9adeee8..c23f792 100644 ---- a/include/parted/geom.in.h -+++ b/include/parted/geom.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1998-2001, 2005, 2007, 2009-2013 Free Software Foundation, -+ Copyright (C) 1998-2001, 2005, 2007, 2009-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/include/parted/natmath.in.h b/include/parted/natmath.in.h -index 284db26..5cf92e9 100644 ---- a/include/parted/natmath.in.h -+++ b/include/parted/natmath.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/parted.in.h b/include/parted/parted.in.h -index 9a4f69c..23e5e49 100644 ---- a/include/parted/parted.in.h -+++ b/include/parted/parted.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/timer.in.h b/include/parted/timer.in.h -index c7c42eb..0f33ce9 100644 ---- a/include/parted/timer.in.h -+++ b/include/parted/timer.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001-2002, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/include/parted/unit.in.h b/include/parted/unit.in.h -index 119cfe3..9d6e06a 100644 ---- a/include/parted/unit.in.h -+++ b/include/parted/unit.in.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/Makefile.am b/libparted/Makefile.am -index bbb43ae..a592b26 100644 ---- a/libparted/Makefile.am -+++ b/libparted/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007, 2009-2014 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/arch/beos.c b/libparted/arch/beos.c -index 6a8a5ae..b1f9642 100644 ---- a/libparted/arch/beos.c -+++ b/libparted/arch/beos.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2006-2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2006-2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/arch/gnu.c b/libparted/arch/gnu.c -index 21d1f35..a17a738 100644 ---- a/libparted/arch/gnu.c -+++ b/libparted/arch/gnu.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2005, 2007, 2009-2013 Free Software Foundation, -+ Copyright (C) 1999-2001, 2005, 2007, 2009-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index f2e2abc..cdb8a26 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/arch/linux.h b/libparted/arch/linux.h -index 865134a..95def1f 100644 ---- a/libparted/arch/linux.h -+++ b/libparted/arch/linux.h -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/architecture.c b/libparted/architecture.c -index b339dc4..df0f381 100644 ---- a/libparted/architecture.c -+++ b/libparted/architecture.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/architecture.h b/libparted/architecture.h -index 98345dd..6c26f0b 100644 ---- a/libparted/architecture.h -+++ b/libparted/architecture.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/cs/constraint.c b/libparted/cs/constraint.c -index 21e80a7..1932aae 100644 ---- a/libparted/cs/constraint.c -+++ b/libparted/cs/constraint.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/cs/geom.c b/libparted/cs/geom.c -index b8726da..1247965 100644 ---- a/libparted/cs/geom.c -+++ b/libparted/cs/geom.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2005, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2005, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/cs/natmath.c b/libparted/cs/natmath.c -index 4ebcb5a..74d3213 100644 ---- a/libparted/cs/natmath.c -+++ b/libparted/cs/natmath.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/debug.c b/libparted/debug.c -index bbc84dc..c47a9f5 100644 ---- a/libparted/debug.c -+++ b/libparted/debug.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/disk.c b/libparted/disk.c -index 5421c03..fe82f44 100644 ---- a/libparted/disk.c -+++ b/libparted/disk.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2003, 2005, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2003, 2005, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/exception.c b/libparted/exception.c -index f4c771d..40f0168 100644 ---- a/libparted/exception.c -+++ b/libparted/exception.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/filesys.c b/libparted/filesys.c -index 1bfe32d..0f8e821 100644 ---- a/libparted/filesys.c -+++ b/libparted/filesys.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/Makefile.am b/libparted/fs/Makefile.am -index 1949617..97a353b 100644 ---- a/libparted/fs/Makefile.am -+++ b/libparted/fs/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007, 2009-2014 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/fs/amiga/a-interface.c b/libparted/fs/amiga/a-interface.c -index f8dd131..1ba12a6 100644 ---- a/libparted/fs/amiga/a-interface.c -+++ b/libparted/fs/amiga/a-interface.c -@@ -1,6 +1,6 @@ - /* - interface.c -- parted support amiga file systems -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/affs.c b/libparted/fs/amiga/affs.c -index a97cc54..c09e8cc 100644 ---- a/libparted/fs/amiga/affs.c -+++ b/libparted/fs/amiga/affs.c -@@ -1,6 +1,6 @@ - /* - affs.c -- parted support for affs file systems -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/affs.h b/libparted/fs/amiga/affs.h -index 5c8cc9c..a089f5d 100644 ---- a/libparted/fs/amiga/affs.h -+++ b/libparted/fs/amiga/affs.h -@@ -1,7 +1,7 @@ - - /* - affs.h -- parted suppoer for affs filesystems header files -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/amiga.c b/libparted/fs/amiga/amiga.c -index 31e1a3b..2e974c2 100644 ---- a/libparted/fs/amiga/amiga.c -+++ b/libparted/fs/amiga/amiga.c -@@ -1,6 +1,6 @@ - /* - libparted/fs_amiga - amiga file system support. -- Copyright (C) 2000-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/amiga.h b/libparted/fs/amiga/amiga.h -index 746030e..34a7d8c 100644 ---- a/libparted/fs/amiga/amiga.h -+++ b/libparted/fs/amiga/amiga.h -@@ -1,6 +1,6 @@ - /* - util.h -- amiga partition table headers. -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/apfs.c b/libparted/fs/amiga/apfs.c -index 2d2cbe1..c21a4fc 100644 ---- a/libparted/fs/amiga/apfs.c -+++ b/libparted/fs/amiga/apfs.c -@@ -1,6 +1,6 @@ - /* - apfs.c -- parted support for apfs file systems -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/apfs.h b/libparted/fs/amiga/apfs.h -index a611db5..6ab9eed 100644 ---- a/libparted/fs/amiga/apfs.h -+++ b/libparted/fs/amiga/apfs.h -@@ -1,6 +1,6 @@ - /* - apfs.h -- parted support for apfs file systems header files -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/asfs.c b/libparted/fs/amiga/asfs.c -index 5824881..0dbf9d9 100644 ---- a/libparted/fs/amiga/asfs.c -+++ b/libparted/fs/amiga/asfs.c -@@ -1,6 +1,6 @@ - /* - asfs.c -- parted asfs filesystem support -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/amiga/asfs.h b/libparted/fs/amiga/asfs.h -index 9b1fb78..0e51cd3 100644 ---- a/libparted/fs/amiga/asfs.h -+++ b/libparted/fs/amiga/asfs.h -@@ -1,6 +1,6 @@ - /* - asfs.h -- parted asfs filesystem support header files -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/btrfs/btrfs.c b/libparted/fs/btrfs/btrfs.c -index 8d76f6f..a5762c0 100644 ---- a/libparted/fs/btrfs/btrfs.c -+++ b/libparted/fs/btrfs/btrfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2013 Free Software Foundation, Inc. -+ Copyright (C) 2013-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ext2/ext2.h b/libparted/fs/ext2/ext2.h -index 4559d6a..0dd87eb 100644 ---- a/libparted/fs/ext2/ext2.h -+++ b/libparted/fs/ext2/ext2.h -@@ -1,6 +1,6 @@ - /* - ext2.h -- ext2 header -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ext2/ext2_fs.h b/libparted/fs/ext2/ext2_fs.h -index b2cd3b2..6784106 100644 ---- a/libparted/fs/ext2/ext2_fs.h -+++ b/libparted/fs/ext2/ext2_fs.h -@@ -15,7 +15,7 @@ - - /* - * EXT2_*_*() convienience macros added by Andrew Clausen -- * Copyright (C) 2000, 2009-2013 Free Software Foundation, Inc. -+ * Copyright (C) 2000, 2009-2014 Free Software Foundation, Inc. - */ - - #ifndef _EXT2_FS_H -diff --git a/libparted/fs/ext2/interface.c b/libparted/fs/ext2/interface.c -index ecafb62..890a47b 100644 ---- a/libparted/fs/ext2/interface.c -+++ b/libparted/fs/ext2/interface.c -@@ -1,6 +1,6 @@ - /* - interface.c -- parted binding glue to libext2resize -- Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/bootsector.c b/libparted/fs/fat/bootsector.c -index 95a8412..cc4aeec 100644 ---- a/libparted/fs/fat/bootsector.c -+++ b/libparted/fs/fat/bootsector.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2013 Free Software -+ Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2014 Free Software - Foundation, Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/fat/bootsector.h b/libparted/fs/fat/bootsector.h -index 449427a..f48d542 100644 ---- a/libparted/fs/fat/bootsector.h -+++ b/libparted/fs/fat/bootsector.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/count.h b/libparted/fs/fat/count.h -index 2c675a3..379930c 100644 ---- a/libparted/fs/fat/count.h -+++ b/libparted/fs/fat/count.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/fat.c b/libparted/fs/fat/fat.c -index 5a409b2..194a8ba 100644 ---- a/libparted/fs/fat/fat.c -+++ b/libparted/fs/fat/fat.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/fat/fat.h b/libparted/fs/fat/fat.h -index 2265871..8f8ca06 100644 ---- a/libparted/fs/fat/fat.h -+++ b/libparted/fs/fat/fat.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/hfs/hfs.c b/libparted/fs/hfs/hfs.c -index e5396b2..1555610 100644 ---- a/libparted/fs/hfs/hfs.c -+++ b/libparted/fs/hfs/hfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2003-2005, 2007, 2009-2013 Free Software Foundation, -+ Copyright (C) 2000, 2003-2005, 2007, 2009-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/hfs/hfs.h b/libparted/fs/hfs/hfs.h -index c3c79d8..6cd27ca 100644 ---- a/libparted/fs/hfs/hfs.h -+++ b/libparted/fs/hfs/hfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2003-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2003-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/hfs/probe.c b/libparted/fs/hfs/probe.c -index c4dca5e..ec62c44 100644 ---- a/libparted/fs/hfs/probe.c -+++ b/libparted/fs/hfs/probe.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/hfs/probe.h b/libparted/fs/hfs/probe.h -index 0dc036a..10c5965 100644 ---- a/libparted/fs/hfs/probe.h -+++ b/libparted/fs/hfs/probe.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/jfs/jfs.c b/libparted/fs/jfs/jfs.c -index c271285..5f0336c 100644 ---- a/libparted/fs/jfs/jfs.c -+++ b/libparted/fs/jfs/jfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/linux_swap/linux_swap.c b/libparted/fs/linux_swap/linux_swap.c -index 0621fa0..ae4fa6e 100644 ---- a/libparted/fs/linux_swap/linux_swap.c -+++ b/libparted/fs/linux_swap/linux_swap.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2002, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2002, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/nilfs2/nilfs2.c b/libparted/fs/nilfs2/nilfs2.c -index 0ec5867..b42a464 100644 ---- a/libparted/fs/nilfs2/nilfs2.c -+++ b/libparted/fs/nilfs2/nilfs2.c -@@ -3,7 +3,7 @@ - * - * Written by Jiro SEKIBA - * -- * Copyright (C) 2011-2013 Free Software Foundation, Inc. -+ * Copyright (C) 2011-2014 Free Software Foundation, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ntfs/ntfs.c b/libparted/fs/ntfs/ntfs.c -index 4c154fd..d533b3c 100644 ---- a/libparted/fs/ntfs/ntfs.c -+++ b/libparted/fs/ntfs/ntfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/bootsector.c b/libparted/fs/r/fat/bootsector.c -index fcb9782..1d2b601 100644 ---- a/libparted/fs/r/fat/bootsector.c -+++ b/libparted/fs/r/fat/bootsector.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2013 Free Software -+ Copyright (C) 1998-2000, 2002, 2004, 2007, 2009-2014 Free Software - Foundation, Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/r/fat/bootsector.h b/libparted/fs/r/fat/bootsector.h -index 6e8b9ce..e92842c 100644 ---- a/libparted/fs/r/fat/bootsector.h -+++ b/libparted/fs/r/fat/bootsector.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/calc.c b/libparted/fs/r/fat/calc.c -index c4c8dba..43a094b 100644 ---- a/libparted/fs/r/fat/calc.c -+++ b/libparted/fs/r/fat/calc.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2002, 2007, 2009-2013 Free Software Foundation, -+ Copyright (C) 1998-2000, 2002, 2007, 2009-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/r/fat/calc.h b/libparted/fs/r/fat/calc.h -index 4d80954..f1bfa7e 100644 ---- a/libparted/fs/r/fat/calc.h -+++ b/libparted/fs/r/fat/calc.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/clstdup.c b/libparted/fs/r/fat/clstdup.c -index 4acbbc8..437948d 100644 ---- a/libparted/fs/r/fat/clstdup.c -+++ b/libparted/fs/r/fat/clstdup.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/clstdup.h b/libparted/fs/r/fat/clstdup.h -index a811c4c..761d5ca 100644 ---- a/libparted/fs/r/fat/clstdup.h -+++ b/libparted/fs/r/fat/clstdup.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/context.c b/libparted/fs/r/fat/context.c -index 7767f14..f67547a 100644 ---- a/libparted/fs/r/fat/context.c -+++ b/libparted/fs/r/fat/context.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/context.h b/libparted/fs/r/fat/context.h -index 5701b1b..7a9fd97 100644 ---- a/libparted/fs/r/fat/context.h -+++ b/libparted/fs/r/fat/context.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/count.c b/libparted/fs/r/fat/count.c -index e551fef..7949e47 100644 ---- a/libparted/fs/r/fat/count.c -+++ b/libparted/fs/r/fat/count.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/count.h b/libparted/fs/r/fat/count.h -index 2c675a3..379930c 100644 ---- a/libparted/fs/r/fat/count.h -+++ b/libparted/fs/r/fat/count.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fat.c b/libparted/fs/r/fat/fat.c -index 8d7420b..5aa72d8 100644 ---- a/libparted/fs/r/fat/fat.c -+++ b/libparted/fs/r/fat/fat.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fat.h b/libparted/fs/r/fat/fat.h -index 943c5e5..704ae55 100644 ---- a/libparted/fs/r/fat/fat.h -+++ b/libparted/fs/r/fat/fat.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fatio.c b/libparted/fs/r/fat/fatio.c -index 75dca0c..5c3a440 100644 ---- a/libparted/fs/r/fat/fatio.c -+++ b/libparted/fs/r/fat/fatio.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/fatio.h b/libparted/fs/r/fat/fatio.h -index f23ab01..11401f2 100644 ---- a/libparted/fs/r/fat/fatio.h -+++ b/libparted/fs/r/fat/fatio.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/resize.c b/libparted/fs/r/fat/resize.c -index 046382b..919acf0 100644 ---- a/libparted/fs/r/fat/resize.c -+++ b/libparted/fs/r/fat/resize.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/table.c b/libparted/fs/r/fat/table.c -index 62bc3b3..adb78a6 100644 ---- a/libparted/fs/r/fat/table.c -+++ b/libparted/fs/r/fat/table.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/table.h b/libparted/fs/r/fat/table.h -index 16180f1..b6517ae 100644 ---- a/libparted/fs/r/fat/table.h -+++ b/libparted/fs/r/fat/table.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/traverse.c b/libparted/fs/r/fat/traverse.c -index 623b6a9..f2efbdf 100644 ---- a/libparted/fs/r/fat/traverse.c -+++ b/libparted/fs/r/fat/traverse.c -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2005, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2005, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/fat/traverse.h b/libparted/fs/r/fat/traverse.h -index 95633cb..1c42f07 100644 ---- a/libparted/fs/r/fat/traverse.h -+++ b/libparted/fs/r/fat/traverse.h -@@ -1,6 +1,6 @@ - /* - libparted -- Copyright (C) 1998-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1998-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/filesys.c b/libparted/fs/r/filesys.c -index 4b8b831..d5d56a7 100644 ---- a/libparted/fs/r/filesys.c -+++ b/libparted/fs/r/filesys.c -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs.c b/libparted/fs/r/hfs/advfs.c -index b5609d6..2398478 100644 ---- a/libparted/fs/r/hfs/advfs.c -+++ b/libparted/fs/r/hfs/advfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs.h b/libparted/fs/r/hfs/advfs.h -index 434d215..60c375d 100644 ---- a/libparted/fs/r/hfs/advfs.h -+++ b/libparted/fs/r/hfs/advfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs_plus.c b/libparted/fs/r/hfs/advfs_plus.c -index b7a95d1..0c5f1c3 100644 ---- a/libparted/fs/r/hfs/advfs_plus.c -+++ b/libparted/fs/r/hfs/advfs_plus.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/advfs_plus.h b/libparted/fs/r/hfs/advfs_plus.h -index 2825c54..130ba65 100644 ---- a/libparted/fs/r/hfs/advfs_plus.h -+++ b/libparted/fs/r/hfs/advfs_plus.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/cache.c b/libparted/fs/r/hfs/cache.c -index 45d8d93..68be366 100644 ---- a/libparted/fs/r/hfs/cache.c -+++ b/libparted/fs/r/hfs/cache.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/cache.h b/libparted/fs/r/hfs/cache.h -index 6196698..a71cd32 100644 ---- a/libparted/fs/r/hfs/cache.h -+++ b/libparted/fs/r/hfs/cache.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file.c b/libparted/fs/r/hfs/file.c -index 70ad3ab..cfb7136 100644 ---- a/libparted/fs/r/hfs/file.c -+++ b/libparted/fs/r/hfs/file.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file.h b/libparted/fs/r/hfs/file.h -index f8a6594..6cbc1de 100644 ---- a/libparted/fs/r/hfs/file.h -+++ b/libparted/fs/r/hfs/file.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file_plus.c b/libparted/fs/r/hfs/file_plus.c -index 2a271da..33c7797 100644 ---- a/libparted/fs/r/hfs/file_plus.c -+++ b/libparted/fs/r/hfs/file_plus.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/file_plus.h b/libparted/fs/r/hfs/file_plus.h -index 0d0c910..ec717e7 100644 ---- a/libparted/fs/r/hfs/file_plus.h -+++ b/libparted/fs/r/hfs/file_plus.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/hfs.c b/libparted/fs/r/hfs/hfs.c -index 26c789a..a1c37cc 100644 ---- a/libparted/fs/r/hfs/hfs.c -+++ b/libparted/fs/r/hfs/hfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2003-2005, 2007, 2009-2013 Free Software Foundation, -+ Copyright (C) 2000, 2003-2005, 2007, 2009-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/fs/r/hfs/hfs.h b/libparted/fs/r/hfs/hfs.h -index c3c79d8..6cd27ca 100644 ---- a/libparted/fs/r/hfs/hfs.h -+++ b/libparted/fs/r/hfs/hfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2003-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2003-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/journal.c b/libparted/fs/r/hfs/journal.c -index 54a065d..9080e14 100644 ---- a/libparted/fs/r/hfs/journal.c -+++ b/libparted/fs/r/hfs/journal.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/journal.h b/libparted/fs/r/hfs/journal.h -index 12551c4..117b440 100644 ---- a/libparted/fs/r/hfs/journal.h -+++ b/libparted/fs/r/hfs/journal.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/probe.c b/libparted/fs/r/hfs/probe.c -index 76b21dc..a1c7f4e 100644 ---- a/libparted/fs/r/hfs/probe.c -+++ b/libparted/fs/r/hfs/probe.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/probe.h b/libparted/fs/r/hfs/probe.h -index c779843..734f102 100644 ---- a/libparted/fs/r/hfs/probe.h -+++ b/libparted/fs/r/hfs/probe.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc.c b/libparted/fs/r/hfs/reloc.c -index abc6b1b..a4af6d3 100644 ---- a/libparted/fs/r/hfs/reloc.c -+++ b/libparted/fs/r/hfs/reloc.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc.h b/libparted/fs/r/hfs/reloc.h -index a5fccaf..74a03ce 100644 ---- a/libparted/fs/r/hfs/reloc.h -+++ b/libparted/fs/r/hfs/reloc.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc_plus.c b/libparted/fs/r/hfs/reloc_plus.c -index 6c2408c..5f4d0b9 100644 ---- a/libparted/fs/r/hfs/reloc_plus.c -+++ b/libparted/fs/r/hfs/reloc_plus.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004-2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004-2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/r/hfs/reloc_plus.h b/libparted/fs/r/hfs/reloc_plus.h -index dc71478..4e17462 100644 ---- a/libparted/fs/r/hfs/reloc_plus.h -+++ b/libparted/fs/r/hfs/reloc_plus.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2004, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2004, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/reiserfs/reiserfs.c b/libparted/fs/reiserfs/reiserfs.c -index 838b2fb..892cb8a 100644 ---- a/libparted/fs/reiserfs/reiserfs.c -+++ b/libparted/fs/reiserfs/reiserfs.c -@@ -1,6 +1,6 @@ - /* - reiserfs.c -- libparted / libreiserfs glue -- Copyright (C) 2001-2002, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/reiserfs/reiserfs.h b/libparted/fs/reiserfs/reiserfs.h -index f215b0b..33a333b 100644 ---- a/libparted/fs/reiserfs/reiserfs.h -+++ b/libparted/fs/reiserfs/reiserfs.h -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/ufs/ufs.c b/libparted/fs/ufs/ufs.c -index a75c082..cf0f441 100644 ---- a/libparted/fs/ufs/ufs.c -+++ b/libparted/fs/ufs/ufs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/fs/xfs/xfs.c b/libparted/fs/xfs/xfs.c -index d4144f8..3fc97db 100644 ---- a/libparted/fs/xfs/xfs.c -+++ b/libparted/fs/xfs/xfs.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/Makefile.am b/libparted/labels/Makefile.am -index 281dce1..c996f81 100644 ---- a/libparted/labels/Makefile.am -+++ b/libparted/labels/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007-2014 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/labels/aix.c b/libparted/labels/aix.c -index 98de112..0fa6fe7 100644 ---- a/libparted/labels/aix.c -+++ b/libparted/labels/aix.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/bsd.c b/libparted/labels/bsd.c -index 79332ab..a8525a4 100644 ---- a/libparted/labels/bsd.c -+++ b/libparted/labels/bsd.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/dasd.c b/libparted/labels/dasd.c -index c09b1d0..fa9414f 100644 ---- a/libparted/labels/dasd.c -+++ b/libparted/labels/dasd.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/dos.c b/libparted/labels/dos.c -index 295fcf3..fa53020 100644 ---- a/libparted/labels/dos.c -+++ b/libparted/labels/dos.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2004-2005, 2007-2013 Free Software Foundation, -+ Copyright (C) 1999-2001, 2004-2005, 2007-2014 Free Software Foundation, - Inc. - - This program is free software; you can redistribute it and/or modify -diff --git a/libparted/labels/dvh.c b/libparted/labels/dvh.c -index 91b9080..158b0b3 100644 ---- a/libparted/labels/dvh.c -+++ b/libparted/labels/dvh.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001-2002, 2005, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2005, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/loop.c b/libparted/labels/loop.c -index 98f9f23..aa233a3 100644 ---- a/libparted/labels/loop.c -+++ b/libparted/labels/loop.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2000, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/mac.c b/libparted/labels/mac.c -index baf2a9f..1034418 100644 ---- a/libparted/labels/mac.c -+++ b/libparted/labels/mac.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000, 2002, 2004, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000, 2002, 2004, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/misc.h b/libparted/labels/misc.h -index c039c5f..d32e0dd 100644 ---- a/libparted/labels/misc.h -+++ b/libparted/labels/misc.h -@@ -1,7 +1,7 @@ - /* -*- Mode: c; indent-tabs-mode: nil -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/pc98.c b/libparted/labels/pc98.c -index ad13c0d..b2ce591 100644 ---- a/libparted/labels/pc98.c -+++ b/libparted/labels/pc98.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/pt-tools.c b/libparted/labels/pt-tools.c -index 547b27c..8100f32 100644 ---- a/libparted/labels/pt-tools.c -+++ b/libparted/labels/pt-tools.c -@@ -1,5 +1,5 @@ - /* partition table tools -- Copyright (C) 2008-2013 Free Software Foundation, Inc. -+ Copyright (C) 2008-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/pt-tools.h b/libparted/labels/pt-tools.h -index 7b5c9f5..cd98a1e 100644 ---- a/libparted/labels/pt-tools.h -+++ b/libparted/labels/pt-tools.h -@@ -1,5 +1,5 @@ - /* libparted - a library for manipulating disk partitions -- Copyright (C) 2008-2013 Free Software Foundation, Inc. -+ Copyright (C) 2008-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/rdb.c b/libparted/labels/rdb.c -index 4cf1463..34b59aa 100644 ---- a/libparted/labels/rdb.c -+++ b/libparted/labels/rdb.c -@@ -2,7 +2,7 @@ - - libparted - a library for manipulating disk partitions - disk_amiga.c - libparted module to manipulate amiga RDB partition tables. -- Copyright (C) 2000-2001, 2004, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2004, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/labels/sun.c b/libparted/labels/sun.c -index 245208e..b23ff86 100644 ---- a/libparted/labels/sun.c -+++ b/libparted/labels/sun.c -@@ -1,7 +1,7 @@ - /* -*- Mode: c; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- - - libparted - a library for manipulating disk partitions -- Copyright (C) 2000-2001, 2005, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2000-2001, 2005, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/libparted.c b/libparted/libparted.c -index 3afbf8e..d5cbb3a 100644 ---- a/libparted/libparted.c -+++ b/libparted/libparted.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/mbr.s b/libparted/mbr.s -index 4a1c5dd..5dd12bd 100644 ---- a/libparted/mbr.s -+++ b/libparted/mbr.s -@@ -1,5 +1,5 @@ - ; libparted - a library for manipulating disk partitions --; Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+; Copyright (C) 1999-2000, 2007, 2009-2014 Free Software Foundation, Inc. - ; - ; This program is free software; you can redistribute it and/or modify - ; it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/Makefile.am b/libparted/tests/Makefile.am -index 12abe60..c7c10a9 100644 ---- a/libparted/tests/Makefile.am -+++ b/libparted/tests/Makefile.am -@@ -1,5 +1,5 @@ - # This file is part of GNU Parted --# Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2007-2014 Free Software Foundation, Inc. - # - # This file may be modified and/or distributed without restriction. - -diff --git a/libparted/tests/t1000-label.sh b/libparted/tests/t1000-label.sh -index afa78dd..188fd10 100755 ---- a/libparted/tests/t1000-label.sh -+++ b/libparted/tests/t1000-label.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the label unit tests in a directory supporting O_DIRECT - --# Copyright (C) 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/t2000-disk.sh b/libparted/tests/t2000-disk.sh -index 1f058bd..c19e490 100755 ---- a/libparted/tests/t2000-disk.sh -+++ b/libparted/tests/t2000-disk.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the disk unit tests in a directory supporting O_DIRECT - --# Copyright (C) 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/t2100-zerolen.sh b/libparted/tests/t2100-zerolen.sh -index f08c8ad..ecd579c 100755 ---- a/libparted/tests/t2100-zerolen.sh -+++ b/libparted/tests/t2100-zerolen.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the zerolen unit tests in a directory supporting O_DIRECT - --# Copyright (C) 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/tests/t3000-symlink.sh b/libparted/tests/t3000-symlink.sh -index 338e44a..4eb5654 100755 ---- a/libparted/tests/t3000-symlink.sh -+++ b/libparted/tests/t3000-symlink.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # run the /dev/mapper symlink test - --# Copyright (C) 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/libparted/timer.c b/libparted/timer.c -index 7999c44..0667051 100644 ---- a/libparted/timer.c -+++ b/libparted/timer.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/libparted/unit.c b/libparted/unit.c -index ff479f1..dddb5db 100644 ---- a/libparted/unit.c -+++ b/libparted/unit.c -@@ -1,6 +1,6 @@ - /* - libparted - a library for manipulating disk partitions -- Copyright (C) 2005, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2005, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/m4/o-direct.m4 b/m4/o-direct.m4 -index f677d37..1f0b77a 100644 ---- a/m4/o-direct.m4 -+++ b/m4/o-direct.m4 -@@ -3,7 +3,7 @@ - # The problem is that on systems supporting O_DIRECT, open with O_DIRECT - # fails for some file system types (e.g., tmpfs on linux-2.6.21). - --# Copyright (C) 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007-2014 Free Software Foundation, Inc. - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, - # with or without modifications, as long as this notice is preserved. -diff --git a/parted/command.c b/parted/command.c -index c592248..e8fa64e 100644 ---- a/parted/command.c -+++ b/parted/command.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/command.h b/parted/command.h -index 0fe43aa..28c3f8e 100644 ---- a/parted/command.h -+++ b/parted/command.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2000, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2000, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/parted.c b/parted/parted.c -index 7a53586..3bf03ea 100644 ---- a/parted/parted.c -+++ b/parted/parted.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2003, 2005-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2003, 2005-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/strlist.c b/parted/strlist.c -index a7a1b23..bca9366 100644 ---- a/parted/strlist.c -+++ b/parted/strlist.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/strlist.h b/parted/strlist.h -index 6df769b..1b67a5d 100644 ---- a/parted/strlist.h -+++ b/parted/strlist.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2001, 2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/table.c b/parted/table.c -index 6c08fd1..b26de3f 100644 ---- a/parted/table.c -+++ b/parted/table.c -@@ -3,7 +3,7 @@ - */ - /* - parted - a frontend to libparted -- Copyright (C) 2006-2013 Free Software Foundation, Inc. -+ Copyright (C) 2006-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/table.h b/parted/table.h -index 12a115a..0487559 100644 ---- a/parted/table.h -+++ b/parted/table.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 2006-2007, 2009-2013 Free Software Foundation, Inc. -+ Copyright (C) 2006-2007, 2009-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/ui.c b/parted/ui.c -index 925110d..7365e7d 100644 ---- a/parted/ui.c -+++ b/parted/ui.c -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2002, 2006-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2002, 2006-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/parted/ui.h b/parted/ui.h -index 260ce37..5e4719b 100644 ---- a/parted/ui.h -+++ b/parted/ui.h -@@ -1,6 +1,6 @@ - /* - parted - a frontend to libparted -- Copyright (C) 1999-2001, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 1999-2001, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/partprobe/partprobe.c b/partprobe/partprobe.c -index 8b744b5..34997fe 100644 ---- a/partprobe/partprobe.c -+++ b/partprobe/partprobe.c -@@ -1,6 +1,6 @@ - /* - partprobe - informs the OS kernel of partition layout -- Copyright (C) 2001-2002, 2007-2013 Free Software Foundation, Inc. -+ Copyright (C) 2001-2002, 2007-2014 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -diff --git a/po/POTFILES.in b/po/POTFILES.in -index a09d7e9..a8e5994 100644 ---- a/po/POTFILES.in -+++ b/po/POTFILES.in -@@ -1,5 +1,5 @@ - # libparted --# Copyright (C) 1999-2001, 2006-2013 Free Software Foundation, Inc. -+# Copyright (C) 1999-2001, 2006-2014 Free Software Foundation, Inc. - # This file may be modified and/or copied without restriction. - - # list of files containing translatable strings -diff --git a/scripts/extract_symvers b/scripts/extract_symvers -index 06b2525..691749e 100755 ---- a/scripts/extract_symvers -+++ b/scripts/extract_symvers -@@ -1,6 +1,6 @@ - #!/bin/sh - --# Copyright (C) 2002-2003, 2007, 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2002-2003, 2007, 2009-2014 Free Software Foundation, Inc. - # - # This file is part of the GNU ISO C++ Library. This library is free - # software; you can redistribute it and/or modify it under the -diff --git a/scripts/update-po b/scripts/update-po -index e860f65..d6d0501 100755 ---- a/scripts/update-po -+++ b/scripts/update-po -@@ -2,7 +2,7 @@ - - # Bootstrap this package from CVS. - --# Copyright (C) 2003-2007, 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2003-2007, 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/help-version.sh b/tests/help-version.sh -index b8053d4..dd32c9f 100755 ---- a/tests/help-version.sh -+++ b/tests/help-version.sh -@@ -2,7 +2,7 @@ - # Make sure all these programs work properly - # when invoked with --help or --version. - --# Copyright (C) 2000-2013 Free Software Foundation, Inc. -+# Copyright (C) 2000-2014 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/init.sh b/tests/init.sh -index bd2048e..b5c2e3f 100644 ---- a/tests/init.sh -+++ b/tests/init.sh -@@ -1,6 +1,6 @@ - # source this file; set up for tests - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0000-basic.sh b/tests/t0000-basic.sh -index 4aca28b..d0107af 100755 ---- a/tests/t0000-basic.sh -+++ b/tests/t0000-basic.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that a simple command using -s succeeds with no prompt - --# Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007, 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0001-tiny.sh b/tests/t0001-tiny.sh -index f3d7b6c..8abc43a 100755 ---- a/tests/t0001-tiny.sh -+++ b/tests/t0001-tiny.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # operate on a very small (1-sector) "disk" - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0010-script-no-ctrl-chars.sh b/tests/t0010-script-no-ctrl-chars.sh -index 947f608..0d7d13f 100755 ---- a/tests/t0010-script-no-ctrl-chars.sh -+++ b/tests/t0010-script-no-ctrl-chars.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that printing with -s outputs no readline control chars - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0100-print.sh b/tests/t0100-print.sh -index d23cfea..61c6d93 100755 ---- a/tests/t0100-print.sh -+++ b/tests/t0100-print.sh -@@ -1,6 +1,6 @@ - #!/bin/sh - # the most basic 'print' test --# Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007, 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0101-print-empty.sh b/tests/t0101-print-empty.sh -index 75b5aa5..3d9a8c9 100755 ---- a/tests/t0101-print-empty.sh -+++ b/tests/t0101-print-empty.sh -@@ -1,6 +1,6 @@ - #!/bin/sh - # test 'parted $dev print' on empty device (without label) --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0200-gpt.sh b/tests/t0200-gpt.sh -index 36f6cd4..c3bd1aa 100755 ---- a/tests/t0200-gpt.sh -+++ b/tests/t0200-gpt.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that printing a GPT partition table does not modify it. - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0201-gpt.sh b/tests/t0201-gpt.sh -index edf99b8..f24caf0 100755 ---- a/tests/t0201-gpt.sh -+++ b/tests/t0201-gpt.sh -@@ -2,7 +2,7 @@ - # avoid failed assertion when creating a GPT on top of an old one for a - # larger device - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0202-gpt-pmbr.sh b/tests/t0202-gpt-pmbr.sh -index f5d5dc8..28f644f 100755 ---- a/tests/t0202-gpt-pmbr.sh -+++ b/tests/t0202-gpt-pmbr.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Preserve first 446B of the Protected MBR for gpt partitions. - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0203-gpt-create-on-min-sized-device.sh b/tests/t0203-gpt-create-on-min-sized-device.sh -index d95d9cd..e2c93bc 100644 ---- a/tests/t0203-gpt-create-on-min-sized-device.sh -+++ b/tests/t0203-gpt-create-on-min-sized-device.sh -@@ -2,7 +2,7 @@ - # parted 3.1 and prior would exit with no diagnostic when failing - # to create a GPT partition table on a device that was too small. - --# Copyright (C) 2012-2013 Free Software Foundation, Inc. -+# Copyright (C) 2012-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0203-gpt-shortened-device-primary-valid.sh b/tests/t0203-gpt-shortened-device-primary-valid.sh -index 1c8e48e..3dd28f8 100755 ---- a/tests/t0203-gpt-shortened-device-primary-valid.sh -+++ b/tests/t0203-gpt-shortened-device-primary-valid.sh -@@ -2,7 +2,7 @@ - # Demonstrate that placing a valid gpt-labeled image on a shorter device - # does not invalidate the primary GPT header. - --# Copyright (C) 2012-2013 Free Software Foundation, Inc. -+# Copyright (C) 2012-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0203-gpt-tiny-device-abort.sh b/tests/t0203-gpt-tiny-device-abort.sh -index 27bb6b1..6a08f32 100644 ---- a/tests/t0203-gpt-tiny-device-abort.sh -+++ b/tests/t0203-gpt-tiny-device-abort.sh -@@ -2,7 +2,7 @@ - # parted before 3.1 could abort while reading a pathologically small device - # with a valid primary GPT header but no room for the backup header. - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0205-gpt-list-clobbers-pmbr.sh b/tests/t0205-gpt-list-clobbers-pmbr.sh -index f12081f..615d83c 100644 ---- a/tests/t0205-gpt-list-clobbers-pmbr.sh -+++ b/tests/t0205-gpt-list-clobbers-pmbr.sh -@@ -5,7 +5,7 @@ - # GPT/MBR table, merely listing the table with Parted-2.1 would clobber - # the MBR part. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh b/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh -index ce67880..311c5f4 100755 ---- a/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh -+++ b/tests/t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh -@@ -3,7 +3,7 @@ - # Much like t0205, but with the addition of a corrupt PTE in primary table, - # "parted $device print" would modify $device. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0207-IEC-binary-notation.sh b/tests/t0207-IEC-binary-notation.sh -index 0ff538f..41f1d33 100644 ---- a/tests/t0207-IEC-binary-notation.sh -+++ b/tests/t0207-IEC-binary-notation.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Show how parted treats a starting or ending sector number w/IEC units. - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0208-mkpart-end-in-IEC.sh b/tests/t0208-mkpart-end-in-IEC.sh -index 33098b4..ffcb480 100644 ---- a/tests/t0208-mkpart-end-in-IEC.sh -+++ b/tests/t0208-mkpart-end-in-IEC.sh -@@ -2,7 +2,7 @@ - # Make sure parted mkpart ends the partition one sector before the specified - # value if end is specified with IEC units. - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0209-gpt-pmbr_boot.sh b/tests/t0209-gpt-pmbr_boot.sh -index 277a356..bb6eb31 100755 ---- a/tests/t0209-gpt-pmbr_boot.sh -+++ b/tests/t0209-gpt-pmbr_boot.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that pmbr_boot flag can be set - --# Copyright (C) 2012-2013 Free Software Foundation, Inc. -+# Copyright (C) 2012-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0210-gpt-resized-partition-entry-array.sh b/tests/t0210-gpt-resized-partition-entry-array.sh -index 86fb8ce..2efc3ca 100755 ---- a/tests/t0210-gpt-resized-partition-entry-array.sh -+++ b/tests/t0210-gpt-resized-partition-entry-array.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # exercise GPT handling of n_partition_array_entries != 128 - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0211-gpt-rewrite-header.sh b/tests/t0211-gpt-rewrite-header.sh -index ee33e43..c747a49 100644 ---- a/tests/t0211-gpt-rewrite-header.sh -+++ b/tests/t0211-gpt-rewrite-header.sh -@@ -5,7 +5,7 @@ - # header to the end of the device. Before parted-3.1, when it attempted - # to do that, starting with a 9-PTE array, it would render the result invalid. - --# Copyright (C) 2012-2013 Free Software Foundation, Inc. -+# Copyright (C) 2012-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0212-gpt-many-partitions.sh b/tests/t0212-gpt-many-partitions.sh -index 55591d9..0b764f9 100644 ---- a/tests/t0212-gpt-many-partitions.sh -+++ b/tests/t0212-gpt-many-partitions.sh -@@ -2,7 +2,7 @@ - # gpt: create many partitions - # Before parted-3.1, this would provoke an invalid free. - --# Copyright (C) 2012-2013 Free Software Foundation, Inc. -+# Copyright (C) 2012-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0220-gpt-msftres.sh b/tests/t0220-gpt-msftres.sh -index 6ce96e8..79518ae 100755 ---- a/tests/t0220-gpt-msftres.sh -+++ b/tests/t0220-gpt-msftres.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # gpt default "flag" for a partition must not be msftres - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0250-gpt.sh b/tests/t0250-gpt.sh -index 54b14b3..c3dd93c 100755 ---- a/tests/t0250-gpt.sh -+++ b/tests/t0250-gpt.sh -@@ -1,6 +1,6 @@ - #!/bin/sh - # very basic GPT table --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0251-gpt-unicode.sh b/tests/t0251-gpt-unicode.sh -index fbffbcb..d2d24ff 100755 ---- a/tests/t0251-gpt-unicode.sh -+++ b/tests/t0251-gpt-unicode.sh -@@ -1,6 +1,6 @@ - #!/bin/sh - # Test unicode partition names --# Copyright (C) 2013 Free Software Foundation, Inc. -+# Copyright (C) 2013-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0280-gpt-corrupt.sh b/tests/t0280-gpt-corrupt.sh -index 80effa0..a7c8d82 100755 ---- a/tests/t0280-gpt-corrupt.sh -+++ b/tests/t0280-gpt-corrupt.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # corrupt a GPT table; ensure parted takes notice - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0281-gpt-grow.sh b/tests/t0281-gpt-grow.sh -index 0cef138..2f34532 100644 ---- a/tests/t0281-gpt-grow.sh -+++ b/tests/t0281-gpt-grow.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # grow a gpt disk, ensure that parted offers to update the gpt size - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2012, 2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0282-gpt-move-backup.sh b/tests/t0282-gpt-move-backup.sh -index 1a296ad..27ef4a6 100644 ---- a/tests/t0282-gpt-move-backup.sh -+++ b/tests/t0282-gpt-move-backup.sh -@@ -2,7 +2,7 @@ - # put backup copy gpt in the wrong place, ensure that - # parted offers to fix - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2012, 2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0283-overlap-partitions.sh b/tests/t0283-overlap-partitions.sh -index 76b2740..f9a3aff 100644 ---- a/tests/t0283-overlap-partitions.sh -+++ b/tests/t0283-overlap-partitions.sh -@@ -2,7 +2,7 @@ - # ensure parted can ignore partitions that overlap or are - # longer than the disk and remove them - --# Copyright (C) 2009-2012 Free Software Foundation, Inc. -+# Copyright (C) 2009-2012, 2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0300-dos-on-gpt.sh b/tests/t0300-dos-on-gpt.sh -index bd09a93..05f9cc6 100755 ---- a/tests/t0300-dos-on-gpt.sh -+++ b/tests/t0300-dos-on-gpt.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # avoid segfault creating a dos PT on top of a gpt one - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0301-overwrite-gpt-pmbr.sh b/tests/t0301-overwrite-gpt-pmbr.sh -index 30756f6..50a40ec 100755 ---- a/tests/t0301-overwrite-gpt-pmbr.sh -+++ b/tests/t0301-overwrite-gpt-pmbr.sh -@@ -2,7 +2,7 @@ - # Test creating a msdos partition over a GPT partition with - # fdisk which doesn't remove the GPT partitions, only the PMBR - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0350-mac-PT-increases-sector-size.sh b/tests/t0350-mac-PT-increases-sector-size.sh -index 45af404..b8b507c 100644 ---- a/tests/t0350-mac-PT-increases-sector-size.sh -+++ b/tests/t0350-mac-PT-increases-sector-size.sh -@@ -3,7 +3,7 @@ - # larger than what the kernel told us (SS) would cause parted to read B - # bytes into a smaller, SS-byte buffer, clobbering heap storage. - --# Copyright (C) 2012-2013 Free Software Foundation, Inc. -+# Copyright (C) 2012-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0400-loop-clobber-infloop.sh b/tests/t0400-loop-clobber-infloop.sh -index b1fc32d..7c595c5 100644 ---- a/tests/t0400-loop-clobber-infloop.sh -+++ b/tests/t0400-loop-clobber-infloop.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # do not infloop in loop_clobber - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0500-dup-clobber.sh b/tests/t0500-dup-clobber.sh -index 28c664d..d85b5f7 100644 ---- a/tests/t0500-dup-clobber.sh -+++ b/tests/t0500-dup-clobber.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Drive the dup-clobber program. - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t0501-duplicate.sh b/tests/t0501-duplicate.sh -index 8affad4..66d321a 100644 ---- a/tests/t0501-duplicate.sh -+++ b/tests/t0501-duplicate.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Drive the dup-clobber program. - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t1100-busy-label.sh b/tests/t1100-busy-label.sh -index a69b1f3..4e256d3 100755 ---- a/tests/t1100-busy-label.sh -+++ b/tests/t1100-busy-label.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # partitioning (parted -s DEV mklabel) a busy disk must fail. - --# Copyright (C) 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t1101-busy-partition.sh b/tests/t1101-busy-partition.sh -index 81ccdb8..eb3fac6 100755 ---- a/tests/t1101-busy-partition.sh -+++ b/tests/t1101-busy-partition.sh -@@ -2,7 +2,7 @@ - # test for Debian bug #582818 (http://bugs.debian.org/582818); forbid - # the removal of a mounted partition. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t1102-loop-label.sh b/tests/t1102-loop-label.sh -index f5701a3..7f9ebfe 100644 ---- a/tests/t1102-loop-label.sh -+++ b/tests/t1102-loop-label.sh -@@ -2,7 +2,7 @@ - # make sure that loop labels work correctly - # create an actual partition - --# Copyright (C) 2013 Free Software Foundation, Inc. -+# Copyright (C) 2013-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index 2ba2f95..79ae5fe 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Probe Ext2, Ext3 and Ext4 file systems - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2200-dos-label-recog.sh b/tests/t2200-dos-label-recog.sh -index 5ca0010..6a929e5 100755 ---- a/tests/t2200-dos-label-recog.sh -+++ b/tests/t2200-dos-label-recog.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # improved MSDOS partition-table recognition - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2201-pc98-label-recog.sh b/tests/t2201-pc98-label-recog.sh -index 83c30df..623886f 100755 ---- a/tests/t2201-pc98-label-recog.sh -+++ b/tests/t2201-pc98-label-recog.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Recognize PC98 labeled disks - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2300-dos-label-extended-bootcode.sh b/tests/t2300-dos-label-extended-bootcode.sh -index b0c26bb..cdc1190 100755 ---- a/tests/t2300-dos-label-extended-bootcode.sh -+++ b/tests/t2300-dos-label-extended-bootcode.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure parted preserves bootcode in extended partition. - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2310-dos-extended-2-sector-min-offset.sh b/tests/t2310-dos-extended-2-sector-min-offset.sh -index 53843ab..10e2e6a 100644 ---- a/tests/t2310-dos-extended-2-sector-min-offset.sh -+++ b/tests/t2310-dos-extended-2-sector-min-offset.sh -@@ -2,7 +2,7 @@ - # Ensure that parted allows a single sector between the beginning - # of an extended partition and the first logical partition. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2400-dos-hfs-partition-type.sh b/tests/t2400-dos-hfs-partition-type.sh -index feb43c5..85d5a5f 100644 ---- a/tests/t2400-dos-hfs-partition-type.sh -+++ b/tests/t2400-dos-hfs-partition-type.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that an HFS partition in a dos table gets the right ID - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t2500-probe-corrupt-hfs.sh b/tests/t2500-probe-corrupt-hfs.sh -index d8a5f1c..403c566 100755 ---- a/tests/t2500-probe-corrupt-hfs.sh -+++ b/tests/t2500-probe-corrupt-hfs.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Do not misbehave when probing a corrupt HFS partition. - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3000-resize-fs.sh b/tests/t3000-resize-fs.sh -index a518080..8cab476 100755 ---- a/tests/t3000-resize-fs.sh -+++ b/tests/t3000-resize-fs.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # exercise the resize library; FAT and HFS+ only - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3200-type-change.sh b/tests/t3200-type-change.sh -index a03fd8c..24854f5 100755 ---- a/tests/t3200-type-change.sh -+++ b/tests/t3200-type-change.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure parted doesn't change the type of a partition to match its FS. - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3300-palo-prep.sh b/tests/t3300-palo-prep.sh -index 88b2c55..8f2890b 100755 ---- a/tests/t3300-palo-prep.sh -+++ b/tests/t3300-palo-prep.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that palo and prep types work properly. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3310-flags.sh b/tests/t3310-flags.sh -index 94b2f2a..cb3024a 100644 ---- a/tests/t3310-flags.sh -+++ b/tests/t3310-flags.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Exercise the exclusive, single-bit flags. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t3400-whole-disk-FAT-partition.sh b/tests/t3400-whole-disk-FAT-partition.sh -index 68f0479..18da752 100755 ---- a/tests/t3400-whole-disk-FAT-partition.sh -+++ b/tests/t3400-whole-disk-FAT-partition.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that a whole-disk FAT partition is detected. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software: you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4000-sun-raid-type.sh b/tests/t4000-sun-raid-type.sh -index 66905cf..858b96c 100755 ---- a/tests/t4000-sun-raid-type.sh -+++ b/tests/t4000-sun-raid-type.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # RAID support on sun disk type - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4001-sun-vtoc.sh b/tests/t4001-sun-vtoc.sh -index 090e070..d70817d 100755 ---- a/tests/t4001-sun-vtoc.sh -+++ b/tests/t4001-sun-vtoc.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that Sun VTOC is properly initialized. - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4100-dvh-partition-limits.sh b/tests/t4100-dvh-partition-limits.sh -index a1bc69a..aeec8fd 100755 ---- a/tests/t4100-dvh-partition-limits.sh -+++ b/tests/t4100-dvh-partition-limits.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # enforce limits on partition start sector and length - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4100-msdos-partition-limits.sh b/tests/t4100-msdos-partition-limits.sh -index 65bda25..09bb5d0 100755 ---- a/tests/t4100-msdos-partition-limits.sh -+++ b/tests/t4100-msdos-partition-limits.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # enforce limits on partition start sector and length - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4100-msdos-starting-sector.sh b/tests/t4100-msdos-starting-sector.sh -index 37b9875..974c8e0 100755 ---- a/tests/t4100-msdos-starting-sector.sh -+++ b/tests/t4100-msdos-starting-sector.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Consistency in msdos free space starting sector. - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4200-partprobe.sh b/tests/t4200-partprobe.sh -index 5ae1a42..261d0e7 100755 ---- a/tests/t4200-partprobe.sh -+++ b/tests/t4200-partprobe.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # partprobe must not examine more than 16 partitions - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t4300-nilfs2-tiny.sh b/tests/t4300-nilfs2-tiny.sh -index 523b6bd..0c954ec 100755 ---- a/tests/t4300-nilfs2-tiny.sh -+++ b/tests/t4300-nilfs2-tiny.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Trigger a nilfs2-related bug. - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t5000-tags.sh b/tests/t5000-tags.sh -index 1d443c3..121e8e7 100755 ---- a/tests/t5000-tags.sh -+++ b/tests/t5000-tags.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # test bios_grub flag in gpt labels - --# Copyright (C) 2007-2013 Free Software Foundation, Inc. -+# Copyright (C) 2007-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6000-dm.sh b/tests/t6000-dm.sh -index c301dee..3513e58 100755 ---- a/tests/t6000-dm.sh -+++ b/tests/t6000-dm.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # ensure that parted can distinguish device map types: linear, multipath - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6001-psep.sh b/tests/t6001-psep.sh -index 809ff9e..f15090a 100644 ---- a/tests/t6001-psep.sh -+++ b/tests/t6001-psep.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # ensure that parted names partitions on dm disks correctly - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6002-dm-busy.sh b/tests/t6002-dm-busy.sh -index c02bf81..723dd30 100644 ---- a/tests/t6002-dm-busy.sh -+++ b/tests/t6002-dm-busy.sh -@@ -2,7 +2,7 @@ - # ensure that parted can alter a partition on a dmraid disk - # while another one is mounted - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6003-dm-hide.sh b/tests/t6003-dm-hide.sh -index 8618adc..fb3b041 100644 ---- a/tests/t6003-dm-hide.sh -+++ b/tests/t6003-dm-hide.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # ensure that parted -l only shows dmraid device-mapper devices - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6004-dm-many-partitions.sh b/tests/t6004-dm-many-partitions.sh -index 4d08e72..8d291ef 100755 ---- a/tests/t6004-dm-many-partitions.sh -+++ b/tests/t6004-dm-many-partitions.sh -@@ -2,7 +2,7 @@ - # device-mapper: create many partitions - # This would not create partitions > 16 when using device-mapper - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012, 2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6005-dm-uuid.sh b/tests/t6005-dm-uuid.sh -index f58cb06..ce1251a 100755 ---- a/tests/t6005-dm-uuid.sh -+++ b/tests/t6005-dm-uuid.sh -@@ -2,7 +2,7 @@ - # device-mapper: preserve uuid - # The dm's partitions uuid would be removed when creating new partitions - --# Copyright (C) 2012 Free Software Foundation, Inc. -+# Copyright (C) 2012, 2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t6100-mdraid-partitions.sh b/tests/t6100-mdraid-partitions.sh -index e980b5d..6f08442 100755 ---- a/tests/t6100-mdraid-partitions.sh -+++ b/tests/t6100-mdraid-partitions.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # verify that new kernel is informed about partitions on mdraid devices - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t7000-scripting.sh b/tests/t7000-scripting.sh -index 94f5409..b939d1d 100755 ---- a/tests/t7000-scripting.sh -+++ b/tests/t7000-scripting.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Make sure the scripting option works (-s) properly. - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t8000-loop.sh b/tests/t8000-loop.sh -index ca4cdc4..ba08a94 100755 ---- a/tests/t8000-loop.sh -+++ b/tests/t8000-loop.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Test usage of loop devices - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t8001-loop-blkpg.sh b/tests/t8001-loop-blkpg.sh -index ad363ff..1363ac2 100755 ---- a/tests/t8001-loop-blkpg.sh -+++ b/tests/t8001-loop-blkpg.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Test support for partitions on loop devices - --# Copyright (C) 2008-2013 Free Software Foundation, Inc. -+# Copyright (C) 2008-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9010-big-sector.sh b/tests/t9010-big-sector.sh -index 4c15327..10e2d51 100755 ---- a/tests/t9010-big-sector.sh -+++ b/tests/t9010-big-sector.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # check physical sector size as reported by 'print' - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9020-alignment.sh b/tests/t9020-alignment.sh -index 482202f..f27b59b 100755 ---- a/tests/t9020-alignment.sh -+++ b/tests/t9020-alignment.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # verify that new alignment-querying functions work - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9021-maxima.sh b/tests/t9021-maxima.sh -index 97b5bbe..510e6c2 100755 ---- a/tests/t9021-maxima.sh -+++ b/tests/t9021-maxima.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # verify that partition maxima-querying functions work - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9022-one-unit-snap.sh b/tests/t9022-one-unit-snap.sh -index 844a78f..9b014e6 100644 ---- a/tests/t9022-one-unit-snap.sh -+++ b/tests/t9022-one-unit-snap.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Confirm that specifying 1 unit snaps to the correct value - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9023-value-lt-one.sh b/tests/t9023-value-lt-one.sh -index cb8fb5f..964657d 100644 ---- a/tests/t9023-value-lt-one.sh -+++ b/tests/t9023-value-lt-one.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Confirm that a value between 0 and 1 throws an error - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9030-align-check.sh b/tests/t9030-align-check.sh -index ed88f8b..eed3975 100644 ---- a/tests/t9030-align-check.sh -+++ b/tests/t9030-align-check.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # exercise the align-check command - --# Copyright (C) 2009-2013 Free Software Foundation, Inc. -+# Copyright (C) 2009-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9040-many-partitions.sh b/tests/t9040-many-partitions.sh -index e9461f6..a3af5e7 100644 ---- a/tests/t9040-many-partitions.sh -+++ b/tests/t9040-many-partitions.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that creating many partitions works. - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9041-undetected-in-use-16th-partition.sh b/tests/t9041-undetected-in-use-16th-partition.sh -index 2c4390d..b763e91 100644 ---- a/tests/t9041-undetected-in-use-16th-partition.sh -+++ b/tests/t9041-undetected-in-use-16th-partition.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that parted knows when N'th (N>=16) partition is mounted - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9042-dos-partition-limit.sh b/tests/t9042-dos-partition-limit.sh -index f3f8ced..b01828c 100644 ---- a/tests/t9042-dos-partition-limit.sh -+++ b/tests/t9042-dos-partition-limit.sh -@@ -1,7 +1,7 @@ - #!/bin/sh - # Ensure that parted enforces msdos partition limit - --# Copyright (C) 2010-2013 Free Software Foundation, Inc. -+# Copyright (C) 2010-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by -diff --git a/tests/t9050-partition-table-types.sh b/tests/t9050-partition-table-types.sh -index d73f45e..390cedf 100755 ---- a/tests/t9050-partition-table-types.sh -+++ b/tests/t9050-partition-table-types.sh -@@ -3,7 +3,7 @@ - # I.e., write a partition table of type T, and then overwrite it - # with one of type V, for every permutation of T and V. - --# Copyright (C) 2011-2013 Free Software Foundation, Inc. -+# Copyright (C) 2011-2014 Free Software Foundation, Inc. - - # This program is free software; you can redistribute it and/or modify - # it under the terms of the GNU General Public License as published by --- -1.9.3 - diff --git a/0118-tests-Add-ntfs-vfat-hfsplus-to-t1700-probe-test.patch b/0118-tests-Add-ntfs-vfat-hfsplus-to-t1700-probe-test.patch deleted file mode 100644 index af15cff..0000000 --- a/0118-tests-Add-ntfs-vfat-hfsplus-to-t1700-probe-test.patch +++ /dev/null @@ -1,66 +0,0 @@ -From 9041a40cb2e1818ac9ca4942d6be70bf3abdc81b Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Thu, 17 Apr 2014 12:14:48 -0700 -Subject: [PATCH 118/125] tests: Add ntfs vfat hfsplus to t1700 probe test - -Add some new filesystems to test. Adjust how mkfs.* tests, since some of -them don't support -V, and add fsname so that the printed filesystem -name doesn't have to match the type. - -* tests/t1700-probe-fs.sh: Add new filesystems to test ---- - tests/t1700-probe-fs.sh | 19 +++++++++++++------ - 1 file changed, 13 insertions(+), 6 deletions(-) - -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index 79ae5fe..c4d514a 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -23,14 +23,21 @@ dev=loop-file - ss=$sector_size_ - n_sectors=$((257*1024)) - --for type in ext2 ext3 ext4 btrfs xfs nilfs2; do -+for type in ext2 ext3 ext4 btrfs xfs nilfs2 ntfs vfat hfsplus; do - -- ( mkfs.$type -V ) >/dev/null 2>&1 \ -+ ( mkfs.$type 2>&1 | grep -i '^usage' ) > /dev/null \ - || { warn_ "$ME: no $type support"; continue; } - -- case $type in ext*) force=-F;; -+ fsname=$type -+ force= -+ case $type in -+ ext*) force=-F;; - xfs) force=-f;; -- *) force=;; esac -+ nilfs2) force=-f;; -+ ntfs) force=-F;; -+ vfat) fsname=fat16;; -+ hfsplus) fsname=hfs+;; -+ esac - - # create an $type file system - dd if=/dev/null of=$dev bs=$ss seek=$n_sectors >/dev/null || fail=1 -@@ -38,9 +45,8 @@ for type in ext2 ext3 ext4 btrfs xfs nilfs2; do - - # probe the $type file system - parted -m -s $dev u s print >out 2>&1 || fail=1 -- grep '^1:.*:'$type'::;$' out || { cat out; fail=1; } -+ grep '^1:.*:'$fsname'::;$' out || { cat out; fail=1; } - rm $dev -- - done - - # Some features should indicate ext4 by themselves. -@@ -55,6 +61,7 @@ for feature in uninit_bg flex_bg; do - # probe the file system, which should now be ext4 - parted -m -s $dev u s print >out 2>&1 || fail=1 - grep '^1:.*:ext4::;$' out || fail=1 -+ rm $dev - done - - Exit $fail --- -1.9.3 - diff --git a/0119-tests-Use-mkfs.xfs-to-create-files-1101112.patch b/0119-tests-Use-mkfs.xfs-to-create-files-1101112.patch deleted file mode 100644 index 9c5d131..0000000 --- a/0119-tests-Use-mkfs.xfs-to-create-files-1101112.patch +++ /dev/null @@ -1,69 +0,0 @@ -From 2b59e3264fc517c432b926968eba8b85d5df788d Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Tue, 27 May 2014 07:38:36 -0700 -Subject: [PATCH 119/125] tests: Use mkfs.xfs to create files (#1101112) - -On s390 there is a bug with mkfs.xfs and pre-existing files. Work around -it by creating the file directly with mkfs.xfs. This also works on other -arches. - -* tests/t1700-probe-fs.sh: Check for xfs and use direct file creation -* tests/t4100-dvh-partition-limits.sh: Use mkfs.xfs -dfile -* tests/t4100-msdos-partition-limits.sh: Use mkfs.xfs -dfile ---- - tests/t1700-probe-fs.sh | 9 +++++++-- - tests/t4100-dvh-partition-limits.sh | 3 +-- - tests/t4100-msdos-partition-limits.sh | 3 +-- - 3 files changed, 9 insertions(+), 6 deletions(-) - -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index c4d514a..c2c9706 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -40,8 +40,13 @@ for type in ext2 ext3 ext4 btrfs xfs nilfs2 ntfs vfat hfsplus; do - esac - - # create an $type file system -- dd if=/dev/null of=$dev bs=$ss seek=$n_sectors >/dev/null || fail=1 -- mkfs.$type $force $dev || { warn_ $ME: mkfs.$type failed; fail=1; continue; } -+ if [ "$type" == "xfs" ]; then -+ # Work around a problem with s390 -+ mkfs.xfs -ssize=$ss -dfile,name=$dev,size=${n_sectors}s || fail=1 -+ else -+ dd if=/dev/null of=$dev bs=$ss seek=$n_sectors >/dev/null || fail=1 -+ mkfs.$type $force $dev || { warn_ $ME: mkfs.$type failed; fail=1; continue; } -+ fi - - # probe the $type file system - parted -m -s $dev u s print >out 2>&1 || fail=1 -diff --git a/tests/t4100-dvh-partition-limits.sh b/tests/t4100-dvh-partition-limits.sh -index aeec8fd..cd89acb 100755 ---- a/tests/t4100-dvh-partition-limits.sh -+++ b/tests/t4100-dvh-partition-limits.sh -@@ -37,8 +37,7 @@ mp=`pwd`/mount-point - n=4096 - - # create an XFS file system --dd if=/dev/zero of=$fs bs=1MB count=2 seek=20 || fail=1 --mkfs.xfs -f -q $fs || fail=1 -+mkfs.xfs -dfile,name=$fs,size=100m || fail=1 - mkdir "$mp" || fail=1 - - # Unmount upon interrupt, failure, etc., as well as upon normal completion. -diff --git a/tests/t4100-msdos-partition-limits.sh b/tests/t4100-msdos-partition-limits.sh -index 09bb5d0..28b4560 100755 ---- a/tests/t4100-msdos-partition-limits.sh -+++ b/tests/t4100-msdos-partition-limits.sh -@@ -37,8 +37,7 @@ mp=`pwd`/mount-point - n=4096 - - # create an XFS file system --dd if=/dev/zero of=$fs bs=1MB count=2 seek=20 || fail=1 --mkfs.xfs -f -q $fs || fail=1 -+mkfs.xfs -dfile,name=$fs,size=100m || fail=1 - mkdir "$mp" || fail=1 - - # Unmount upon interrupt, failure, etc., as well as upon normal completion. --- -1.9.3 - diff --git a/0120-maint-fix-make-syntax-check-nits.patch b/0120-maint-fix-make-syntax-check-nits.patch deleted file mode 100644 index 7021b0d..0000000 --- a/0120-maint-fix-make-syntax-check-nits.patch +++ /dev/null @@ -1,161 +0,0 @@ -From 591c7f6f39fff9126d7aa05c24e95961a91fd27f Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 25 May 2014 21:16:44 -0700 -Subject: [PATCH 120/125] maint: fix "make syntax-check" nits - -* doc/parted.texi: Update copyright year to 2014. -* tests/gpt-header-move.py: Remove empty line at EOF. -* tests/t0281-gpt-grow.sh: Correct reversed args to compare. -* tests/t0282-gpt-move-backup.sh: Likewise. -* libparted/labels/gpt.c (gpt_partition_set_name): Change "Can not" -to "failed to" in diagnostic. -(gpt_partition_get_name): Likewise. -* tests/t1102-loop-label.sh (dev): Remove trailing space in -here document that creates expected output, and strip that -same trailing space from actual output. -* libparted/fs/jfs/jfs.c: Do not cast alloca return value. -* libparted/fs/reiserfs/reiserfs.c: Likewise. -* libparted/fs/xfs/xfs.c: Likewise. ---- - doc/parted.texi | 2 +- - libparted/fs/jfs/jfs.c | 2 +- - libparted/fs/reiserfs/reiserfs.c | 3 +-- - libparted/fs/xfs/xfs.c | 2 +- - libparted/labels/gpt.c | 4 ++-- - tests/gpt-header-move.py | 1 - - tests/t0281-gpt-grow.sh | 2 +- - tests/t0282-gpt-move-backup.sh | 2 +- - tests/t1102-loop-label.sh | 4 ++-- - 9 files changed, 10 insertions(+), 12 deletions(-) - -diff --git a/doc/parted.texi b/doc/parted.texi -index 97ce203..2b6f7f8 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -14,7 +14,7 @@ and manipulating partition tables. - @ifnottex @c texi2pdf don't understand copying and insertcopying ??? - @c modifications must also be done in the titlepage - @copying --Copyright @copyright{} 1999-2013 Free Software Foundation, Inc. -+Copyright @copyright{} 1999-2014 Free Software Foundation, Inc. - - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.3 or -diff --git a/libparted/fs/jfs/jfs.c b/libparted/fs/jfs/jfs.c -index 5f0336c..47b2f07 100644 ---- a/libparted/fs/jfs/jfs.c -+++ b/libparted/fs/jfs/jfs.c -@@ -37,7 +37,7 @@ - static PedGeometry* - jfs_probe (PedGeometry* geom) - { -- struct superblock *sb = (struct superblock *)alloca (geom->dev->sector_size); -+ struct superblock *sb = alloca (geom->dev->sector_size); - - if (geom->length * geom->dev->sector_size < JFS_SUPER_OFFSET) - return NULL; -diff --git a/libparted/fs/reiserfs/reiserfs.c b/libparted/fs/reiserfs/reiserfs.c -index 892cb8a..2efcdf3 100644 ---- a/libparted/fs/reiserfs/reiserfs.c -+++ b/libparted/fs/reiserfs/reiserfs.c -@@ -57,8 +57,7 @@ static PedGeometry *reiserfs_probe(PedGeometry *geom) - int i; - - PED_ASSERT(geom != NULL); -- reiserfs_super_block_t *sb = -- (reiserfs_super_block_t *)alloca (geom->dev->sector_size); -+ reiserfs_super_block_t *sb = alloca (geom->dev->sector_size); - - for (i = 0; reiserfs_super_offset[i] != -1; i++) { - if (reiserfs_super_offset[i] >= geom->length) -diff --git a/libparted/fs/xfs/xfs.c b/libparted/fs/xfs/xfs.c -index 3fc97db..e4314a8 100644 ---- a/libparted/fs/xfs/xfs.c -+++ b/libparted/fs/xfs/xfs.c -@@ -38,7 +38,7 @@ xfs_probe (PedGeometry* geom) - { - PedSector block_size; - PedSector block_count; -- struct xfs_sb *sb = (struct xfs_sb *)alloca (geom->dev->sector_size); -+ struct xfs_sb *sb = alloca (geom->dev->sector_size); - - if (geom->length < XFS_SB_DADDR + 1) - return NULL; -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 76bf7e7..2a08a50 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -1896,7 +1896,7 @@ gpt_partition_set_name (PedPartition *part, const char *name) - err: - ped_exception_throw (PED_EXCEPTION_WARNING, - PED_EXCEPTION_IGNORE, -- _("Can not translate partition name")); -+ _("failed to translate partition name")); - iconv_close (conv); - } - -@@ -1923,7 +1923,7 @@ gpt_partition_get_name (const PedPartition *part) - err: - ped_exception_throw (PED_EXCEPTION_WARNING, - PED_EXCEPTION_IGNORE, -- _("Can not translate partition name")); -+ _("failed to translate partition name")); - iconv_close (conv); - return ""; - } -diff --git a/tests/gpt-header-move.py b/tests/gpt-header-move.py -index 977febb..8bee6bb 100644 ---- a/tests/gpt-header-move.py -+++ b/tests/gpt-header-move.py -@@ -37,4 +37,3 @@ file.seek(512*(altlba-32)) - file.write(backup) - file.write(gptheader) - file.write("\0" * (512 * 33)) -- -diff --git a/tests/t0281-gpt-grow.sh b/tests/t0281-gpt-grow.sh -index 2f34532..36a2530 100644 ---- a/tests/t0281-gpt-grow.sh -+++ b/tests/t0281-gpt-grow.sh -@@ -95,6 +95,6 @@ compare exp out || fail=1 - - parted -s $dev print > err 2>&1 || fail=1 - grep Warning: err > k ; mv k err --compare err /dev/null || fail=1 -+compare /dev/null err || fail=1 - - Exit $fail -diff --git a/tests/t0282-gpt-move-backup.sh b/tests/t0282-gpt-move-backup.sh -index 27ef4a6..b827672 100644 ---- a/tests/t0282-gpt-move-backup.sh -+++ b/tests/t0282-gpt-move-backup.sh -@@ -95,6 +95,6 @@ compare exp out || fail=1 - - parted -s $dev print > err 2>&1 || fail=1 - grep Error: err > k ; mv k err --compare err /dev/null || fail=1 -+compare /dev/null err || fail=1 - - Exit $fail -diff --git a/tests/t1102-loop-label.sh b/tests/t1102-loop-label.sh -index 7f9ebfe..c6574c2 100644 ---- a/tests/t1102-loop-label.sh -+++ b/tests/t1102-loop-label.sh -@@ -34,13 +34,13 @@ Model: Linux scsi_debug (scsi) - Disk DEVICE: 94.4MB - Sector size (logical/physical): ${ss}B/${ss}B - Partition Table: loop --Disk Flags: -+Disk Flags: - - Number Start End Size File system Flags - 1 0.00B 94.4MB 94.4MB ext2 - - EOF --mv out o2 && sed -e "s,$dev,DEVICE,;" o2 > out -+mv out o2 && sed -e "s,$dev,DEVICE,;s/ *$//" o2 > out - - compare exp out || fail=1 - parted -s $dev rm 1 || fail=1 --- -1.9.3 - diff --git a/0121-tests-avoid-false-positive-failure-due-to-symlink.patch b/0121-tests-avoid-false-positive-failure-due-to-symlink.patch deleted file mode 100644 index 1e38b91..0000000 --- a/0121-tests-avoid-false-positive-failure-due-to-symlink.patch +++ /dev/null @@ -1,47 +0,0 @@ -From 9e661325e5725c13dbaab898b183f286b193baf7 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Sun, 25 May 2014 16:52:06 -0700 -Subject: [PATCH 121/125] tests: avoid false-positive failure due to symlink - -* tests/t6000-dm.sh (sanitize): Helper function. -Before this change, this test would fail due to difference between -absolute name and symlink-including names in "parted print" output ---- - tests/t6000-dm.sh | 10 ++++++++-- - 1 file changed, 8 insertions(+), 2 deletions(-) - -diff --git a/tests/t6000-dm.sh b/tests/t6000-dm.sh -index 3513e58..5b29660 100755 ---- a/tests/t6000-dm.sh -+++ b/tests/t6000-dm.sh -@@ -47,6 +47,12 @@ f1=$(pwd)/1; d1=$(loop_setup_ "$f1") \ - f2=$(pwd)/2 && d2=$(loop_setup_ "$f2") || fail=1 - f3=$(pwd)/3 && d3=$(loop_setup_ "$f3") || fail=1 - -+# In the output of parted's print -s command, -+# replace (possibly varying) $dev name with '...'. -+sanitize() { -+ sed 's,^Disk .*: \([0-9][0-9]*\),Disk ...: \1,;s/ *$//' "$@" -+} -+ - # This loop used to include "multipath", but lvm2 changed - # in such a way that that no longer works with loop devices. - # FIXME: use two scsi_debug devices instead. -@@ -72,12 +78,12 @@ for type in linear ; do - compare /dev/null out || fail=1 - - parted -s "$dev" print > out 2>&1 || fail=1 -- sed 's/ $//' out > k && mv k out || fail=1 # Remove trailing blank. -+ sanitize out > k && mv k out || fail=1 - - # Create expected output file. - cat <> exp || fail=1 - Model: Linux device-mapper ($type) (dm) --Disk $dev: 524kB -+Disk ...: 524kB - Sector size (logical/physical): 512B/512B - Partition Table: msdos - Disk Flags: --- -1.9.3 - diff --git a/0122-tests-use-test-s-operator-not.patch b/0122-tests-use-test-s-operator-not.patch deleted file mode 100644 index 1903c59..0000000 --- a/0122-tests-use-test-s-operator-not.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 1da239e2ebd260efa1b9dce9e19127b6bd4bb906 Mon Sep 17 00:00:00 2001 -From: Jim Meyering -Date: Wed, 28 May 2014 08:56:31 -0700 -Subject: [PATCH 122/125] tests: use test's "=" operator, not "==" - -* tests/t1700-probe-fs.sh: Avoid "make syntax-check" error: s/==/=/ ---- - tests/t1700-probe-fs.sh | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/tests/t1700-probe-fs.sh b/tests/t1700-probe-fs.sh -index c2c9706..574d6fe 100755 ---- a/tests/t1700-probe-fs.sh -+++ b/tests/t1700-probe-fs.sh -@@ -40,7 +40,7 @@ for type in ext2 ext3 ext4 btrfs xfs nilfs2 ntfs vfat hfsplus; do - esac - - # create an $type file system -- if [ "$type" == "xfs" ]; then -+ if [ "$type" = "xfs" ]; then - # Work around a problem with s390 - mkfs.xfs -ssize=$ss -dfile,name=$dev,size=${n_sectors}s || fail=1 - else --- -1.9.3 - diff --git a/0123-libparted-Fix-part-dupe-with-empty-name.patch b/0123-libparted-Fix-part-dupe-with-empty-name.patch deleted file mode 100644 index 5174042..0000000 --- a/0123-libparted-Fix-part-dupe-with-empty-name.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 06241515a818dcf62e7c5728a8328cf165e3a793 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Jun 2014 12:13:48 -0700 -Subject: [PATCH 123/134] libparted: Fix part dupe with empty name - -It was setting the original translated_name to 0, not the new copy. - -* libparted/labels/gpt.c (gpt_partition_duplicate): fix empty name ---- - libparted/labels/gpt.c | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c -index 2a08a50..d69377a 100644 ---- a/libparted/labels/gpt.c -+++ b/libparted/labels/gpt.c -@@ -1407,9 +1407,11 @@ gpt_partition_duplicate (const PedPartition *part) - goto error_free_part; - - *result_data = *part_data; -- if (part_data->translated_name) -+ if (part_data->translated_name) { - result_data->translated_name = xstrdup (part_data->translated_name); -- else part_data->translated_name = 0; -+ } else { -+ result_data->translated_name = 0; -+ } - return result; - - error_free_part: --- -1.9.3 - diff --git a/0124-tests-check-name-when-duplicating.patch b/0124-tests-check-name-when-duplicating.patch deleted file mode 100644 index 084241d..0000000 --- a/0124-tests-check-name-when-duplicating.patch +++ /dev/null @@ -1,82 +0,0 @@ -From 8d2c819b9ec89ca7c29c061eb2fd438c3876d6f8 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Jun 2014 12:13:49 -0700 -Subject: [PATCH 124/134] tests: check name when duplicating - -Create a second partition with a name when supported by the disk label. -Check to make sure that the duplicate has copied over the name. The goal -with this was to try to catch the bug fixed by the previous commit but I -was unable to make it fail. But this should improve our test coverage -anyway. - -* tests/duplicate.c: Add a partition name test. ---- - tests/duplicate.c | 33 +++++++++++++++++++++++++++++---- - 1 file changed, 29 insertions(+), 4 deletions(-) - -diff --git a/tests/duplicate.c b/tests/duplicate.c -index 129537c..a9dde84 100644 ---- a/tests/duplicate.c -+++ b/tests/duplicate.c -@@ -50,7 +50,7 @@ main (int argc, char **argv) - const PedGeometry *geometry = ped_geometry_new (dev, 34, 1024); - assert (geometry); - PedPartition *part = ped_partition_new (disk, part_type, fs_type, -- geometry->start, geometry->end); -+ geometry->start, geometry->end); - assert (part); - PedConstraint *constraint = ped_constraint_exact (geometry); - assert (constraint); -@@ -65,6 +65,22 @@ main (int argc, char **argv) - if (ped_partition_is_flag_available (part, PED_PARTITION_LBA)) - ped_partition_set_flag (part, PED_PARTITION_LBA, 1); - -+ /* Add a 2nd partition with a name (when supported) */ -+ geometry = ped_geometry_new (dev, 1500, 500); -+ assert (geometry); -+ part = ped_partition_new (disk, part_type, fs_type, -+ geometry->start, geometry->end); -+ assert (part); -+ constraint = ped_constraint_exact (geometry); -+ assert (constraint); -+ assert (ped_disk_add_partition (disk, part, constraint)); -+ ped_constraint_destroy (constraint); -+ assert (ped_partition_set_system (part, fs_type)); -+ if (ped_partition_is_flag_available (part, PED_PARTITION_LBA)) -+ ped_partition_set_flag (part, PED_PARTITION_LBA, 1); -+ if (ped_disk_type_check_feature (part->disk->type, PED_DISK_TYPE_PARTITION_NAME)) -+ ped_partition_set_name(part, "foobarbaz"); -+ - assert (ped_disk_commit(disk)); - - /* Duplicate it */ -@@ -114,14 +130,23 @@ main (int argc, char **argv) - - /* Check the flags */ - for (PedPartitionFlag flag = PED_PARTITION_FIRST_FLAG; -- flag <= PED_PARTITION_LAST_FLAG; flag++) { -+ flag <= PED_PARTITION_LAST_FLAG; flag++) -+ { - if (!ped_partition_is_flag_available(disk_part, flag)) - continue; - fprintf (stderr, "Checking partition flag %d\n", flag); - fprintf (stderr, "%d ? %d\n", ped_partition_get_flag (disk_part, flag), -- ped_partition_get_flag (copy_part, flag)); -+ ped_partition_get_flag (copy_part, flag)); - assert (ped_partition_get_flag (disk_part, flag) -- == ped_partition_get_flag (copy_part, flag)); -+ == ped_partition_get_flag (copy_part, flag)); -+ } -+ -+ /* Check the name, if supported */ -+ if (ped_disk_type_check_feature (part->disk->type, PED_DISK_TYPE_PARTITION_NAME)) -+ { -+ const char *disk_name = ped_partition_get_name(disk_part); -+ const char *copy_name = ped_partition_get_name(copy_part); -+ assert (strcmp (disk_name, copy_name) == 0); - } - } - --- -1.9.3 - diff --git a/0125-Fix-python-test-scripts-for-distribution.patch b/0125-Fix-python-test-scripts-for-distribution.patch deleted file mode 100644 index 0370535..0000000 --- a/0125-Fix-python-test-scripts-for-distribution.patch +++ /dev/null @@ -1,245 +0,0 @@ -From e8078b3a7b7652aa5f9ee6e09f3c6b21d2810b07 Mon Sep 17 00:00:00 2001 -From: "Brian C. Lane" -Date: Wed, 11 Jun 2014 12:13:50 -0700 -Subject: [PATCH 125/134] Fix python test scripts for distribution - -make distcheck was failing because these scripts were not being -included. - -Make them both executable and and add the path to the tests that use -them. They also need to be included in the distribution so update -Makefile.am - -* tests/Makefile.am: Add python test scripts -* tests/gpt-header-move.py: rename to gpt-header-move and make it - executable -* tests/msdos-overlap.py: rename to overlap.py -* tests/t0282-gpt-move-backup.sh: add path to scripts and use new name -* tests/t0283-overlap-partitions.sh: same ---- - tests/Makefile.am | 3 ++- - tests/gpt-header-move | 41 +++++++++++++++++++++++++++++++++++++++ - tests/gpt-header-move.py | 39 ------------------------------------- - tests/msdos-overlap | 25 ++++++++++++++++++++++++ - tests/msdos-overlap.py | 25 ------------------------ - tests/t0282-gpt-move-backup.sh | 4 ++-- - tests/t0283-overlap-partitions.sh | 4 ++-- - 7 files changed, 72 insertions(+), 69 deletions(-) - create mode 100755 tests/gpt-header-move - delete mode 100644 tests/gpt-header-move.py - create mode 100755 tests/msdos-overlap - delete mode 100755 tests/msdos-overlap.py - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 26226cf..0b5b1b6 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -85,7 +85,8 @@ TESTS = \ - - EXTRA_DIST = \ - $(TESTS) t-local.sh t-lvm.sh \ -- init.cfg init.sh t-lib-helpers.sh gpt-header-munge -+ init.cfg init.sh t-lib-helpers.sh gpt-header-munge \ -+ gpt-header-move msdos-overlap - - check_PROGRAMS = print-align print-max dup-clobber duplicate fs-resize - fs_resize_LDADD = \ -diff --git a/tests/gpt-header-move b/tests/gpt-header-move -new file mode 100755 -index 0000000..05cdc65 ---- /dev/null -+++ b/tests/gpt-header-move -@@ -0,0 +1,41 @@ -+#!/usr/bin/python -+ -+# open img file, subtract 33 from altlba address, and move the last 33 sectors -+# back by 33 sectors -+ -+from struct import * -+from zipfile import crc32 -+import array -+import sys -+file = open(sys.argv[1],'rb+') -+file.seek(512) -+gptheader = file.read(512) -+altlba = unpack_from('" -+ sys.exit(1) -+ -+data = "".join(chr(c) for c in BAD_ENTRY) -+with open(sys.argv[1], "rb+") as f: -+ f.seek(OFFSET, 0) -+ f.write(data) -+ -+sys.exit(0) -diff --git a/tests/msdos-overlap.py b/tests/msdos-overlap.py -deleted file mode 100755 -index 5bddfb0..0000000 ---- a/tests/msdos-overlap.py -+++ /dev/null -@@ -1,25 +0,0 @@ --#!/usr/bin/python --""" -- Write an overlapping partition to a msdos disk -- -- Call with disk image/device to mangle --""" --import sys -- --BAD_ENTRY = (0x72, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -- 0x01, 0x10, 0x83, 0x03, 0x20, 0x4f, 0x00, 0x08, -- 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, -- 0x00, 0x50, 0x83, 0x00, 0x0a, 0x7a, 0xff, 0x27, -- 0x00, 0x00, 0x0a, 0x15, 0x00, 0x00, 0x00, 0x00 ) --OFFSET = 0x1b8 -- --if len(sys.argv) < 2: -- print "%s: " -- sys.exit(1) -- --data = "".join(chr(c) for c in BAD_ENTRY) --with open(sys.argv[1], "rb+") as f: -- f.seek(OFFSET, 0) -- f.write(data) -- --sys.exit(0) -diff --git a/tests/t0282-gpt-move-backup.sh b/tests/t0282-gpt-move-backup.sh -index b827672..c197279 100644 ---- a/tests/t0282-gpt-move-backup.sh -+++ b/tests/t0282-gpt-move-backup.sh -@@ -17,7 +17,7 @@ - # You should have received a copy of the GNU General Public License - # along with this program. If not, see . - --. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted $srcdir - require_512_byte_sector_size_ - dev=loop-file - -@@ -40,7 +40,7 @@ printf "BYT;\n$dev:${n_sectors}s:file:$sector_size_:$sector_size_:gpt::;\n" \ - compare exp out || fail=1 - - # move the backup --python ../gpt-header-move.py $dev || fail=1 -+gpt-header-move $dev || fail=1 - - # printing must warn, but not fix in script mode - parted -s $dev print > out 2>&1 || fail=1 -diff --git a/tests/t0283-overlap-partitions.sh b/tests/t0283-overlap-partitions.sh -index f9a3aff..7928c94 100644 ---- a/tests/t0283-overlap-partitions.sh -+++ b/tests/t0283-overlap-partitions.sh -@@ -17,13 +17,13 @@ - # You should have received a copy of the GNU General Public License - # along with this program. If not, see . - --. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted $srcdir - require_512_byte_sector_size_ - dev=loop-file - - truncate -s 10m $dev || framework_failure - parted -s $dev mklabel msdos || framework_failure --python ../msdos-overlap.py $dev || framework_failure -+msdos-overlap $dev || framework_failure - - # print the empty table - parted ---pretend-input-tty $dev < out 2>&1 || fail=1 --- -1.9.3 - diff --git a/0126-parted-add-resizepart-command.patch b/0126-parted-add-resizepart-command.patch deleted file mode 100644 index 150441e..0000000 --- a/0126-parted-add-resizepart-command.patch +++ /dev/null @@ -1,146 +0,0 @@ -From 21c58e17c473ea8ef31a18d03348eb2381c0f36c Mon Sep 17 00:00:00 2001 -From: Petr Uzel -Date: Mon, 26 Sep 2011 17:21:01 +0200 -Subject: [PATCH 126/134] parted: add resizepart command - -Add resizepart command to resize ( change the end position ) an existing -partition. Note that it does nothing to a filesystem in the partition. ---- - NEWS | 2 ++ - parted/parted.c | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 88 insertions(+) - -diff --git a/NEWS b/NEWS -index 3de5dde..7069020 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,6 +4,8 @@ GNU parted NEWS -*- outline -*- - - ** New Features - -+ Add resizepart command to resize a partition -+ - Add support for EAV DASD partitions, which are ECKD's with more than - 65520 cylinders. - -diff --git a/parted/parted.c b/parted/parted.c -index 3bf03ea..a36ca28 100644 ---- a/parted/parted.c -+++ b/parted/parted.c -@@ -153,6 +153,9 @@ static const char* fs_type_msg_start = N_("FS-TYPE is one of: "); - static const char* start_end_msg = N_("START and END are disk locations, such as " - "4GB or 10%. Negative values count from the end of the disk. " - "For example, -1s specifies exactly the last sector.\n"); -+static const char* end_msg = N_("END is disk location, such as " -+ "4GB or 10%. Negative value counts from the end of the disk. " -+ "For example, -1s specifies exactly the last sector.\n"); - static const char* state_msg = N_("STATE is one of: on, off\n"); - static const char* device_msg = N_("DEVICE is usually /dev/hda or /dev/sda\n"); - static const char* name_msg = N_("NAME is any word you want\n"); -@@ -437,6 +440,21 @@ constraint_from_start_end (PedDevice* dev, PedGeometry* range_start, - range_start, range_end, 1, dev->length); - } - -+ -+static PedConstraint* -+constraint_from_start_end_fixed_start (PedDevice* dev, PedSector start_sector, -+ PedGeometry* range_end) -+{ -+ PedGeometry range_start; -+ range_start.dev = dev; -+ range_start.start = start_sector; -+ range_start.end = start_sector; -+ range_start.length = 1; -+ -+ return ped_constraint_new (ped_alignment_any, ped_alignment_any, -+ &range_start, range_end, 1, dev->length); -+} -+ - void - help_on (char* topic) - { -@@ -1484,6 +1502,66 @@ error: - } - - static int -+do_resizepart (PedDevice** dev, PedDisk** diskp) -+{ -+ PedDisk *disk = *diskp; -+ PedPartition *part = NULL; -+ PedSector start, end, oldend; -+ PedGeometry *range_end = NULL; -+ PedConstraint* constraint; -+ int rc = 0; -+ -+ if (!disk) { -+ disk = ped_disk_new (*dev); -+ *diskp = disk; -+ } -+ if (!disk) -+ goto error; -+ -+ if (ped_disk_is_flag_available(disk, PED_DISK_CYLINDER_ALIGNMENT)) -+ if (!ped_disk_set_flag(disk, PED_DISK_CYLINDER_ALIGNMENT, -+ alignment == ALIGNMENT_CYLINDER)) -+ goto error; -+ -+ if (!command_line_get_partition (_("Partition number?"), disk, &part)) -+ goto error; -+ if (!_partition_warn_busy (part)) -+ goto error; -+ -+ start = part->geom.start; -+ end = oldend = part->geom.end; -+ if (!command_line_get_sector (_("End?"), *dev, &end, &range_end, NULL)) -+ goto error; -+ /* Do not move start of the partition */ -+ constraint = constraint_from_start_end_fixed_start (*dev, start, range_end); -+ if (!ped_disk_set_partition_geom (disk, part, constraint, -+ start, end)) -+ goto error_destroy_constraint; -+ /* warn when shrinking partition - might lose data */ -+ if (part->geom.end < oldend) -+ if (ped_exception_throw ( -+ PED_EXCEPTION_WARNING, -+ PED_EXCEPTION_YES_NO, -+ _("Shrinking a partition can cause data loss, " \ -+ "are you sure you want to continue?")) != PED_EXCEPTION_YES) -+ goto error_destroy_constraint; -+ ped_disk_commit (disk); -+ -+ if ((*dev)->type != PED_DEVICE_FILE) -+ disk_is_modified = 1; -+ -+ rc = 1; -+ -+error_destroy_constraint: -+ ped_constraint_destroy (constraint); -+error: -+ if (range_end != NULL) -+ ped_geometry_destroy (range_end); -+ return rc; -+} -+ -+ -+static int - do_rm (PedDevice** dev, PedDisk** diskp) - { - PedPartition* part = NULL; -@@ -1906,6 +1984,14 @@ NULL), - str_list_create (_(start_end_msg), NULL), 1)); - - command_register (commands, command_create ( -+ str_list_create_unique ("resizepart", _("resizepart"), NULL), -+ do_resizepart, -+ str_list_create ( -+_("resizepart NUMBER END resize partition NUMBER"), -+NULL), -+ str_list_create (_(number_msg), _(end_msg), NULL), 1)); -+ -+command_register (commands, command_create ( - str_list_create_unique ("rm", _("rm"), NULL), - do_rm, - str_list_create ( --- -1.9.3 - diff --git a/0127-tests-excersise-resize-command.patch b/0127-tests-excersise-resize-command.patch deleted file mode 100644 index 1cee9aa..0000000 --- a/0127-tests-excersise-resize-command.patch +++ /dev/null @@ -1,122 +0,0 @@ -From 33fd692cb14045fdc13306cd57cfe2040328daa8 Mon Sep 17 00:00:00 2001 -From: Petr Uzel -Date: Tue, 27 Sep 2011 09:11:29 +0200 -Subject: [PATCH 127/134] tests: excersise resize command - -a lot of TODOs ---- - tests/Makefile.am | 1 + - tests/t3200-resize-partition.sh | 89 +++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 90 insertions(+) - create mode 100755 tests/t3200-resize-partition.sh - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 0b5b1b6..b726366 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -50,6 +50,7 @@ TESTS = \ - t2400-dos-hfs-partition-type.sh \ - t2500-probe-corrupt-hfs.sh \ - t3000-resize-fs.sh \ -+ t3200-resize-partition.sh \ - t3200-type-change.sh \ - t3300-palo-prep.sh \ - t3310-flags.sh \ -diff --git a/tests/t3200-resize-partition.sh b/tests/t3200-resize-partition.sh -new file mode 100755 -index 0000000..251b545 ---- /dev/null -+++ b/tests/t3200-resize-partition.sh -@@ -0,0 +1,89 @@ -+#!/bin/sh -+# exercise the resize sub-command -+# based on t3000-resize-fs.sh test -+ -+# Copyright (C) 2009-2011 Free Software Foundation, Inc. -+ -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 3 of the License, or -+# (at your option) any later version. -+ -+# 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. -+ -+# You should have received a copy of the GNU General Public License -+# along with this program. If not, see . -+ -+. "${srcdir=.}/init.sh"; path_prepend_ ../parted -+ -+require_root_ -+require_scsi_debug_module_ -+ -+ss=$sector_size_ -+ -+default_start=1024s -+default_end=2048s -+ -+# create memory-backed device -+scsi_debug_setup_ dev_size_mb=5 > dev-name || -+ skip_ 'failed to create scsi_debug device' -+dev=$(cat dev-name) -+ -+# TODO test simple shrink -+# TODO test expand past end of the disk -+# TODO test expand past begin of next partition -+# TODO test shrink before start -+# TODO test everything with GPT -+# TODO more tests with extended/logical partitions -+ -+parted -s $dev mklabel msdos > out 2> err || fail=1 -+# expect no output -+compare /dev/null out || fail=1 -+compare /dev/null err || fail=1 -+ -+# ensure that the disk is large enough -+dev_n_sectors=$(parted -s $dev u s p|sed -n '2s/.* \([0-9]*\)s$/\1/p') -+device_sectors_required=$(echo $default_end | sed 's/s$//') -+# Ensure that $dev is large enough for this test -+test $device_sectors_required -le $dev_n_sectors || fail=1 -+ -+# create an empty partition -+parted -a minimal -s $dev mkpart primary $default_start $default_end > out 2>&1 || fail=1 -+compare /dev/null out || fail=1 -+ -+# print partition table -+parted -m -s $dev u s p > out 2>&1 || fail=1 -+ -+# FIXME: check expected output -+ -+# wait for new partition device to appear -+wait_for_dev_to_appear_ ${dev}1 || { warn_ "${dev}1 did not appear" fail=1; } -+sleep 1 -+ -+ -+# extend the filesystem to end on sector 4096 -+new_end=4096s -+parted -s $dev resizepart 1 $new_end > out 2> err || fail=1 -+# expect no output -+compare /dev/null out || fail=1 -+compare /dev/null err || fail=1 -+ -+# print partition table -+parted -m -s $dev u s p > out 2>&1 || fail=1 -+ -+sed -n 3p out > k && mv k out || fail=1 -+printf "1:$default_start:$new_end:3073s:::$ms;\n" > exp || fail=1 -+compare exp out || fail=1 -+ -+# Remove the partition explicitly, so that mklabel doesn't evoke a warning. -+parted -s $dev rm 1 || fail=1 -+ -+# Create a clean partition table for the next iteration. -+parted -s $dev mklabel msdos > out 2>&1 || fail=1 -+# expect no output -+compare /dev/null out || fail=1 -+ -+Exit $fail --- -1.9.3 - diff --git a/0128-libparted-Add-support-for-partition-resize.patch b/0128-libparted-Add-support-for-partition-resize.patch deleted file mode 100644 index 6de3159..0000000 --- a/0128-libparted-Add-support-for-partition-resize.patch +++ /dev/null @@ -1,331 +0,0 @@ -From f09ca967a0bc443b869a6fad5b5ffe8e95c3fe9a Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Tue, 29 Nov 2011 14:05:48 -0500 -Subject: [PATCH 128/134] libparted: Add support for partition resize - -When resizing a partition ( same partition number, same -start sector, different end sector ), try to use the -new BLKPG_RES_PARTITION request to update the kernel -partition table with the new size. Also handle resizing -devmapper targets. ---- - NEWS | 3 +- - libparted/arch/linux.c | 207 +++++++++++++++++++++++++++++++++++++++++-------- - 2 files changed, 177 insertions(+), 33 deletions(-) - -diff --git a/NEWS b/NEWS -index 7069020..ad2fea1 100644 ---- a/NEWS -+++ b/NEWS -@@ -4,7 +4,8 @@ GNU parted NEWS -*- outline -*- - - ** New Features - -- Add resizepart command to resize a partition -+ Add resizepart command to resize a partition. This works even on -+ mounted partitions. - - Add support for EAV DASD partitions, which are ECKD's with more than - 65520 cylinders. -diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c -index cdb8a26..0f18904 100644 ---- a/libparted/arch/linux.c -+++ b/libparted/arch/linux.c -@@ -2493,8 +2493,9 @@ _blkpg_add_partition (PedDisk* disk, const PedPartition *part) - } - linux_part.length *= disk->dev->sector_size; - } -- else -+ else { - linux_part.length = part->geom.length * disk->dev->sector_size; -+ } - linux_part.pno = part->num; - strncpy (linux_part.devname, dev_name, BLKPG_DEVNAMELTH); - if (vol_name) -@@ -2521,6 +2522,60 @@ _blkpg_remove_partition (PedDisk* disk, int n) - BLKPG_DEL_PARTITION); - } - -+#ifdef BLKPG_RESIZE_PARTITION -+static int _blkpg_resize_partition (PedDisk* disk, const PedPartition *part) -+{ -+ struct blkpg_partition linux_part; -+ char* dev_name; -+ -+ PED_ASSERT(disk != NULL); -+ PED_ASSERT(disk->dev->sector_size % PED_SECTOR_SIZE_DEFAULT == 0); -+ -+ dev_name = _device_get_part_path (disk->dev, part->num); -+ if (!dev_name) -+ return 0; -+ memset (&linux_part, 0, sizeof (linux_part)); -+ linux_part.start = part->geom.start * disk->dev->sector_size; -+ /* see fs/partitions/msdos.c:msdos_partition(): "leave room for LILO" */ -+ if (part->type & PED_PARTITION_EXTENDED) { -+ if (disk->dev->sector_size == 512) { -+ linux_part.length = 2; -+ PedPartition *walk; -+ /* if the second sector is claimed by a logical partition, -+ then there's just no room for lilo, so don't try to use it */ -+ for (walk = part->part_list; walk; walk = walk->next) { -+ if (walk->geom.start == part->geom.start+1) -+ linux_part.length = 1; -+ } -+ } else linux_part.length = 1; -+ } -+ else -+ linux_part.length = part->geom.length * disk->dev->sector_size; -+ linux_part.pno = part->num; -+ strncpy (linux_part.devname, dev_name, BLKPG_DEVNAMELTH); -+ -+ free (dev_name); -+ -+ if (!_blkpg_part_command (disk->dev, &linux_part, -+ BLKPG_RESIZE_PARTITION)) { -+ return ped_exception_throw ( -+ PED_EXCEPTION_ERROR, -+ PED_EXCEPTION_IGNORE_CANCEL, -+ _("Error informing the kernel about modifications to " -+ "partition %s -- %s. This means Linux won't know " -+ "about any changes you made to %s until you reboot " -+ "-- so you shouldn't mount it or use it in any way " -+ "before rebooting."), -+ linux_part.devname, -+ strerror (errno), -+ linux_part.devname) -+ == PED_EXCEPTION_IGNORE; -+ } -+ -+ return 1; -+} -+#endif -+ - /* Read the integer from /sys/block/DEV_BASE/ENTRY and set *VAL - to that value, where DEV_BASE is the last component of DEV->path. - Upon success, return true. Otherwise, return false. */ -@@ -2789,6 +2844,76 @@ err: - free (vol_name); - return 0; - } -+ -+static int -+_dm_resize_partition (PedDisk* disk, const PedPartition* part) -+{ -+ LinuxSpecific* arch_specific = LINUX_SPECIFIC (disk->dev); -+ char* params = NULL; -+ char* vol_name = NULL; -+ const char* dev_name = NULL; -+ uint32_t cookie = 0; -+ -+ /* Get map name from devicemapper */ -+ struct dm_task *task = dm_task_create (DM_DEVICE_INFO); -+ if (!task) -+ goto err; -+ -+ if (!dm_task_set_major_minor (task, arch_specific->major, -+ arch_specific->minor, 0)) -+ goto err; -+ -+ if (!dm_task_run(task)) -+ goto err; -+ -+ dev_name = dm_task_get_name (task); -+ size_t name_len = strlen (dev_name); -+ vol_name = zasprintf ("%s%s%d", -+ dev_name, -+ isdigit (dev_name[name_len - 1]) ? "p" : "", -+ part->num); -+ if (vol_name == NULL) -+ goto err; -+ -+ /* Caution: dm_task_destroy frees dev_name. */ -+ dm_task_destroy (task); -+ task = NULL; -+ if ( ! (params = zasprintf ("%d:%d %lld", arch_specific->major, -+ arch_specific->minor, part->geom.start))) -+ goto err; -+ -+ task = dm_task_create (DM_DEVICE_RELOAD); -+ if (!task) -+ goto err; -+ -+ dm_task_set_name (task, vol_name); -+ dm_task_add_target (task, 0, part->geom.length, -+ "linear", params); -+ if (!dm_task_set_cookie (task, &cookie, 0)) -+ goto err; -+ if (dm_task_run (task)) { -+ dm_task_destroy (task); -+ task = dm_task_create (DM_DEVICE_RESUME); -+ if (!task) -+ goto err; -+ dm_task_set_name (task, vol_name); -+ if (!dm_task_set_cookie (task, &cookie, 0)) -+ goto err; -+ if (dm_task_run (task)) { -+ free (params); -+ free (vol_name); -+ return 1; -+ } -+ } -+err: -+ dm_task_update_nodes(); -+ if (task) -+ dm_task_destroy (task); -+ free (params); -+ free (vol_name); -+ return 0; -+} -+ - #endif - - /* -@@ -2810,9 +2935,10 @@ _disk_sync_part_table (PedDisk* disk) - { - PED_ASSERT(disk != NULL); - PED_ASSERT(disk->dev != NULL); -- int lpn; -+ int lpn, lpn2; - unsigned int part_range = _device_get_partition_range(disk->dev); - int (*add_partition)(PedDisk* disk, const PedPartition *part); -+ int (*resize_partition)(PedDisk* disk, const PedPartition *part); - int (*remove_partition)(PedDisk* disk, int partno); - bool (*get_partition_start_and_length)(PedPartition const *part, - unsigned long long *start, -@@ -2822,10 +2948,16 @@ _disk_sync_part_table (PedDisk* disk) - if (disk->dev->type == PED_DEVICE_DM) { - add_partition = _dm_add_partition; - remove_partition = _dm_remove_partition; -+ resize_partition = _dm_resize_partition; - get_partition_start_and_length = _dm_get_partition_start_and_length; - } else { - add_partition = _blkpg_add_partition; - remove_partition = _blkpg_remove_partition; -+#ifdef BLKPG_RESIZE_PARTITION -+ resize_partition = _blkpg_resize_partition; -+#else -+ resize_partition = NULL; -+#endif - get_partition_start_and_length = _kernel_get_partition_start_and_length; - } - -@@ -2835,7 +2967,11 @@ _disk_sync_part_table (PedDisk* disk) - lpn = PED_MAX(lpn, part_range); - else - lpn = part_range; -- -+ /* for add pass, use lesser of device or label limit */ -+ if (ped_disk_get_max_supported_partition_count(disk, &lpn2)) -+ lpn2 = PED_MIN(lpn2, part_range); -+ else -+ lpn2 = part_range; - /* Its not possible to support largest_partnum < 0. - * largest_partnum == 0 would mean does not support partitions. - * */ -@@ -2860,9 +2996,10 @@ _disk_sync_part_table (PedDisk* disk) - if (get_partition_start_and_length(part, - &start, &length) - && start == part->geom.start -- && length == part->geom.length) -+ && (length == part->geom.length -+ || (resize_partition && part->num < lpn2))) - { -- /* partition is unchanged, so nothing to do */ -+ /* partition is unchanged, or will be resized so nothing to do */ - ok[i - 1] = 1; - continue; - } -@@ -2882,13 +3019,8 @@ _disk_sync_part_table (PedDisk* disk) - } while (n_sleep--); - if (!ok[i - 1] && errnums[i - 1] == ENXIO) - ok[i - 1] = 1; /* it already doesn't exist */ -- } -- /* lpn = largest partition number. -- * for add pass, use lesser of device or label limit */ -- if (ped_disk_get_max_supported_partition_count(disk, &lpn)) -- lpn = PED_MIN(lpn, part_range); -- else -- lpn = part_range; -+ } -+ lpn = lpn2; - /* don't actually add partitions for loop */ - if (strcmp (disk->type->name, "loop") == 0) - lpn = 0; -@@ -2901,11 +3033,22 @@ _disk_sync_part_table (PedDisk* disk) - /* get start and length of existing partition */ - if (get_partition_start_and_length(part, - &start, &length) -- && start == part->geom.start -- && length == part->geom.length) { -- ok[i - 1] = 1; -- /* partition is unchanged, so nothing to do */ -- continue; -+ && start == part->geom.start) -+ { -+ if (length == part->geom.length) { -+ ok[i - 1] = 1; -+ /* partition is unchanged, so nothing to do */ -+ continue; -+ } -+ if (resize_partition -+ && start == part->geom.start) -+ { -+ /* try to resize */ -+ if (resize_partition (disk, part)) { -+ ok[i - 1] = 1; -+ continue; -+ } -+ } - } - /* add the (possibly modified or new) partition */ - if (!add_partition (disk, part)) { -@@ -2917,31 +3060,31 @@ _disk_sync_part_table (PedDisk* disk) - char *bad_part_list = NULL; - /* now warn about any errors */ - for (i = 1; i <= lpn; i++) { -- if (ok[i - 1] || errnums[i - 1] == ENXIO) -- continue; -- if (bad_part_list == NULL) { -- bad_part_list = malloc (lpn * 5); -- if (!bad_part_list) -- goto cleanup; -- bad_part_list[0] = 0; -- } -- sprintf (bad_part_list + strlen (bad_part_list), "%d, ", i); -- } -+ if (ok[i - 1] || errnums[i - 1] == ENXIO) -+ continue; -+ if (bad_part_list == NULL) { -+ bad_part_list = malloc (lpn * 5); -+ if (!bad_part_list) -+ goto cleanup; -+ bad_part_list[0] = 0; -+ } -+ sprintf (bad_part_list + strlen (bad_part_list), "%d, ", i); -+ } - if (bad_part_list == NULL) -- ret = 1; -- else { -+ ret = 1; -+ else { - bad_part_list[strlen (bad_part_list) - 2] = 0; - if (ped_exception_throw ( - PED_EXCEPTION_ERROR, - PED_EXCEPTION_IGNORE_CANCEL, - _("Partition(s) %s on %s have been written, but we have " -- "been unable to inform the kernel of the change, " -- "probably because it/they are in use. As a result, " -+ "been unable to inform the kernel of the change, " -+ "probably because it/they are in use. As a result, " - "the old partition(s) will remain in use. You " - "should reboot now before making further changes."), - bad_part_list, disk->dev->path) == PED_EXCEPTION_IGNORE) - ret = 1; -- free (bad_part_list); -+ free (bad_part_list); - } - cleanup: - free (errnums); --- -1.9.3 - diff --git a/0129-parted-make-_partition_warn_busy-actually-a-warning-.patch b/0129-parted-make-_partition_warn_busy-actually-a-warning-.patch deleted file mode 100644 index 63d2de6..0000000 --- a/0129-parted-make-_partition_warn_busy-actually-a-warning-.patch +++ /dev/null @@ -1,105 +0,0 @@ -From f46146a15bf45478569c1d364661d3d54f8e3a1a Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Wed, 30 Nov 2011 13:13:58 -0500 -Subject: [PATCH 129/134] parted: make _partition_warn_busy actually a warning - instead of an error - -This function was throwing a PED_EXCEPTION_ERROR with only the -PED_EXCEPTION_CANCEL option. Converted to a PED_EXCEPTION_WARNING -with the option to continue anyhow. ---- - NEWS | 3 +++ - parted/parted.c | 17 ++++++++++------- - tests/t1101-busy-partition.sh | 2 +- - tests/t1102-loop-label.sh | 3 +-- - tests/t9041-undetected-in-use-16th-partition.sh | 4 ++-- - 5 files changed, 17 insertions(+), 12 deletions(-) - -diff --git a/NEWS b/NEWS -index ad2fea1..118f459 100644 ---- a/NEWS -+++ b/NEWS -@@ -134,6 +134,9 @@ GNU parted NEWS -*- outline -*- - - ** Changes in behavior - -+ When attempting to manipulate a mounted partition, parted now issues -+ a warning that you can choose to ignore, instead of an error. -+ - When creating a loop label, it automatically comes with a partition - using the whole disk. - -diff --git a/parted/parted.c b/parted/parted.c -index a36ca28..ec9e04e 100644 ---- a/parted/parted.c -+++ b/parted/parted.c -@@ -224,14 +224,17 @@ _partition_warn_busy (PedPartition* part) - - if (ped_partition_is_busy (part)) { - path = ped_partition_get_path (part); -- ped_exception_throw ( -- PED_EXCEPTION_ERROR, -- PED_EXCEPTION_CANCEL, -- _("Partition %s is being used. You must unmount it " -- "before you modify it with Parted."), -- path); -+ if (ped_exception_throw ( -+ PED_EXCEPTION_WARNING, -+ PED_EXCEPTION_YES_NO, -+ _("Partition %s is being used. Are you sure you " \ -+ "want to continue?"), -+ path) != PED_EXCEPTION_YES) -+ { -+ free (path); -+ return 0; -+ } - free (path); -- return 0; - } - return 1; - } -diff --git a/tests/t1101-busy-partition.sh b/tests/t1101-busy-partition.sh -index eb3fac6..ad091f7 100755 ---- a/tests/t1101-busy-partition.sh -+++ b/tests/t1101-busy-partition.sh -@@ -29,7 +29,7 @@ scsi_debug_setup_ dev_size_mb=80 > dev-name || - dev=$(cat dev-name) - - cat < exp-error || framework_failure --Error: Partition ${dev}2 is being used. You must unmount it before you modify it with Parted. -+Warning: Partition ${dev}2 is being used. Are you sure you want to continue? - EOF - - parted -s "$dev" mklabel msdos > out 2>&1 || fail=1 -diff --git a/tests/t1102-loop-label.sh b/tests/t1102-loop-label.sh -index c6574c2..9752002 100644 ---- a/tests/t1102-loop-label.sh -+++ b/tests/t1102-loop-label.sh -@@ -73,8 +73,7 @@ compare exp out || fail=1 - # make sure partition busy check works ( mklabel checks whole disk ) - parted -s "$dev" rm 1 > out 2>&1; test $? = 1 || fail=1 - # create expected output file --echo "Error: Partition $dev is being used. You must unmount it before you modify \ --it with Parted." > exp -+echo "Warning: Partition ${dev} is being used. Are you sure you want to continue?" > exp - compare exp out || fail=1 - - umount "$mount_point" -diff --git a/tests/t9041-undetected-in-use-16th-partition.sh b/tests/t9041-undetected-in-use-16th-partition.sh -index b763e91..edaae1b 100644 ---- a/tests/t9041-undetected-in-use-16th-partition.sh -+++ b/tests/t9041-undetected-in-use-16th-partition.sh -@@ -87,8 +87,8 @@ for part_dev in $partitions; do - # Removal of mounted partition must fail. - parted -s $scsi_dev rm $n > out 2>&1 && fail=1 - -- echo "Error: Partition $part_dev is being used." \ -- 'You must unmount it before you modify it with Parted.' \ -+ echo "Warning: Partition $part_dev is being used." \ -+ 'Are you sure you want to continue?' \ - > exp-error || framework_failure_ - - # expect error --- -1.9.3 - diff --git a/0130-parted-Allow-undocumented-commands.patch b/0130-parted-Allow-undocumented-commands.patch deleted file mode 100644 index 990c064..0000000 --- a/0130-parted-Allow-undocumented-commands.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 360d6277d674c6f92135c8b6bf274c48675ef168 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Mon, 5 Dec 2011 19:24:39 -0500 -Subject: [PATCH 130/134] parted: Allow undocumented commands - -Have command_print_summary print nothing if the command summary is NULL. -This allows for a command to be registered, but not documented in the -output of help. ---- - parted/command.c | 2 ++ - 1 file changed, 2 insertions(+) - -diff --git a/parted/command.c b/parted/command.c -index e8fa64e..bc70e8a 100644 ---- a/parted/command.c -+++ b/parted/command.c -@@ -118,6 +118,8 @@ command_get_names (Command** list) - void - command_print_summary (Command* cmd) - { -+ if (cmd->summary == NULL) -+ return; - fputs (" ", stdout); - str_list_print_wrap (cmd->summary, screen_width(), 2, 8, stdout); - putchar ('\n'); --- -1.9.3 - diff --git a/0131-parted-Add-stub-resize-command-for-backward-compatib.patch b/0131-parted-Add-stub-resize-command-for-backward-compatib.patch deleted file mode 100644 index 7fb28da..0000000 --- a/0131-parted-Add-stub-resize-command-for-backward-compatib.patch +++ /dev/null @@ -1,50 +0,0 @@ -From 56bfbe21ecca0cb6466c78baed192dc2e5401676 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Tue, 8 Jan 2013 19:40:35 -0500 -Subject: [PATCH 131/134] parted: Add stub resize command for backward - compatibility - -To make sure that older scripts trying to use the resize command do not -accidentally run the new resizepart command by mistake, this undocumented -stub command will throw an error if called. ---- - parted/parted.c | 16 ++++++++++++++++ - 1 file changed, 16 insertions(+) - -diff --git a/parted/parted.c b/parted/parted.c -index ec9e04e..f27a035 100644 ---- a/parted/parted.c -+++ b/parted/parted.c -@@ -1505,6 +1505,16 @@ error: - } - - static int -+do_resize (PedDevice **dev, PedDisk** diskp) -+{ -+ ped_exception_throw ( -+ PED_EXCEPTION_ERROR, -+ PED_EXCEPTION_CANCEL, -+ _("The resize command has been removed in parted 3.0")); -+ return 0; -+} -+ -+static int - do_resizepart (PedDevice** dev, PedDisk** diskp) - { - PedDisk *disk = *diskp; -@@ -1987,6 +1997,12 @@ NULL), - str_list_create (_(start_end_msg), NULL), 1)); - - command_register (commands, command_create ( -+ str_list_create_unique ("resize", _("resize"), NULL), -+ do_resize, -+ NULL, -+ str_list_create (_(N_("The resize command was removed in parted 3.0\n")), NULL), 1)); -+ -+command_register (commands, command_create ( - str_list_create_unique ("resizepart", _("resizepart"), NULL), - do_resizepart, - str_list_create ( --- -1.9.3 - diff --git a/0132-Document-resizepart-command.patch b/0132-Document-resizepart-command.patch deleted file mode 100644 index acaef53..0000000 --- a/0132-Document-resizepart-command.patch +++ /dev/null @@ -1,62 +0,0 @@ -From 5c793853fe5cb0718d895c3394fb909c73c6fa1e Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 25 May 2014 14:43:39 -0400 -Subject: [PATCH 132/134] Document resizepart command - ---- - doc/C/parted.8 | 4 ++++ - doc/parted.texi | 16 ++++++++++++++++ - 2 files changed, 20 insertions(+) - -diff --git a/doc/C/parted.8 b/doc/C/parted.8 -index f8e6a3d..689011c 100644 ---- a/doc/C/parted.8 -+++ b/doc/C/parted.8 -@@ -93,6 +93,10 @@ Rescue a lost partition that was located somewhere between \fIstart\fP and - \fIend\fP. If a partition is found, \fBparted\fP will ask if you want to - create an entry for it in the partition table. - .TP -+.B resizepart \fIpartition\fP \fIend\fP -+Change the \fIend\fP position of \fIpartition\fP. Note that this does not -+modify any filesystem present in the partition. -+.TP - .B rm \fIpartition\fP - Delete \fIpartition\fP. - .TP -diff --git a/doc/parted.texi b/doc/parted.texi -index 2b6f7f8..07aa702 100644 ---- a/doc/parted.texi -+++ b/doc/parted.texi -@@ -423,6 +423,7 @@ GNU Parted provides the following commands: - * print:: - * quit:: - * rescue:: -+* resizepart:: - * rm:: - * select:: - * set:: -@@ -744,6 +745,21 @@ It's back! :) - - @end deffn - -+@node resizepart -+@subsection resizepart -+@cindex resizepart, command description -+@cindex command description, resizepart -+ -+@deffn Command resizepart @var{number} @var{end} -+ -+Moves the @var{end} position of partition @var{number}. Note that this -+does not modify any filesystem present in the partition. If you wish to -+do this, you will need to use external tools, such as @command{resize2fs}. -+ -+When growing a partition you will want to grow the filesystem afterwards, -+but when shrinking, you need to shrink the filesystem before the partition. -+@end deffn -+ - @node rm - @subsection rm - @cindex rm, command description --- -1.9.3 - diff --git a/0133-tests-fix-t9020-alignment.sh.patch b/0133-tests-fix-t9020-alignment.sh.patch deleted file mode 100644 index d0c3165..0000000 --- a/0133-tests-fix-t9020-alignment.sh.patch +++ /dev/null @@ -1,28 +0,0 @@ -From ae37d7c4586664e18f42e25a7f210f392e1f0100 Mon Sep 17 00:00:00 2001 -From: Phillip Susi -Date: Sun, 15 Jun 2014 18:20:07 -0400 -Subject: [PATCH 133/134] tests: fix t9020-alignment.sh - -This test was refering to print-alignment by absolute path, which -broke building with a different object directory, causing -make distcheck to fail. ---- - tests/t9020-alignment.sh | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/tests/t9020-alignment.sh b/tests/t9020-alignment.sh -index f27b59b..9ea6eb0 100755 ---- a/tests/t9020-alignment.sh -+++ b/tests/t9020-alignment.sh -@@ -36,7 +36,7 @@ scsi_debug_setup_ physblk_exp=3 lowest_aligned=7 num_parts=4 > dev-name || - scsi_dev=$(cat dev-name) - - # print alignment info --"$abs_srcdir/print-align" $scsi_dev > out 2>&1 || fail=1 -+../print-align $scsi_dev > out 2>&1 || fail=1 - - compare exp out || fail=1 - --- -1.9.3 - diff --git a/parted.spec b/parted.spec index cc9118f..8ce6ccf 100644 --- a/parted.spec +++ b/parted.spec @@ -3,161 +3,17 @@ Summary: The GNU disk partition manipulation program Name: parted -Version: 3.1 -Release: 29%{?dist} +Version: 3.1.90 +Release: 1%{?dist} License: GPLv3+ Group: Applications/System URL: http://www.gnu.org/software/parted -Source0: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz -Source1: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz.sig +Source0: http://alpha.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz +Source1: http://alpha.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz.sig Source2: pubkey.jim.meyering +Source3: pubkey.phillip.susi -Patch0001: 0001-maint-post-release-administrivia.patch -Patch0002: 0002-libparted-check-PMBR-before-GPT-partition-table.patch -Patch0003: 0003-tests-add-t0301-overwrite-gpt-pmbr.sh.patch -Patch0004: 0004-tests-remove-bogus-envvar-setting-from-t0300-dos-on-.patch -Patch0005: 0005-gpt-fix-endianness-bug-in-gpt_get_max_supported_part.patch -Patch0006: 0006-tests-add-a-test-to-exercise-just-fixed-code.patch -Patch0007: 0007-maint-avoid-new-syntax-check-failure-re-xref.patch -Patch0008: 0008-maint-don-t-prohibit-strncpy-just-yet.patch -# Won't work when applied to the tar.xz -#Patch0009: 0009-build-update-gnulib-bootstrap-and-init.sh.patch -Patch0010: 0010-build-prefer-AM_CPPFLAGS-over-INCLUDES.patch -Patch0011: 0011-build-don-t-list-files-with-unknown-suffix-in-_SOURC.patch -Patch0012: 0012-build-prefer-pattern-rules-over-suffix-rules.patch -Patch0013: 0013-build-enable-subdir-objects-Automake-option-globally.patch -Patch0014: 0014-tests-prefer-AM_TESTS_ENVIRONMENT-over-TESTS_ENVIRON.patch -Patch0015: 0015-tests-remove-unused-AM_TESTS_ENVIRONMENT-entries.patch -# No bootstrap.conf in tar.xz -#Patch0016: 0016-build-require-Automake-1.11.6.patch -#Patch0017: 0017-maint-make-Autoconf-version-requirement-consistent.patch -#Patch0018: 0018-maint-tighten-per-version-requirement.patch -Patch0019: 0019-maint-remove-unnecessary-wcslen-use.patch -Patch0020: 0020-tests-clarify-a-comment-_reading_-gpt-tables-on-tiny.patch -Patch0021: 0021-gpt-require-first_usable_LBA-last_usable_LBA.patch -Patch0022: 0022-tests-update-t7000-scripting.sh-to-avoid-new-FP.patch -Patch0023: 0023-gpt-permit-mklabel-gpt-on-a-67-sector-device.patch -Patch0024: 0024-gpt-when-mklabel-gpt-fails-always-provide-a-diagnost.patch -Patch0025: 0025-tests-show-that-small-dev-now-evokes-mklabel-gpt-dia.patch -Patch0026: 0026-tests-avoid-syntax-check-failure-for-reversed-compar.patch -Patch0027: 0027-mac-don-t-let-larger-partition-table-specified-block.patch -Patch0028: 0028-tests-mac-exercise-the-just-fixed-bug.patch -Patch0029: 0029-add-support-for-a-new-Linux-specific-GPT-partition-t.patch -Patch0030: 0030-tests-clean-up-tests.patch -Patch0031: 0031-doc-libparted-disk.c-correct-doxygen-comment-typo.patch -Patch0032: 0032-tests-stop-using-private-dev-directory-for-losetup.patch -# Won't apply to tar.xz -#Patch0033: 0033-maint-fix-an-error-in-the-preceding-commit-log.patch -Patch0034: 0034-tests-improve-test-for-partitionable-loop-devices.patch -Patch0035: 0035-tests-t8001-do-not-rely-on-modprobe-loop.patch -Patch0036: 0036-build-do-not-rely-on-automake-s-AM_TESTS_ENVIRONMENT.patch -# No .gitignore in tar.xz -#Patch0037: 0037-build-.gitignore-ignore-tests-fs-resize.patch -Patch0038: 0038-partprobe-remove-no-update-long-option.patch -Patch0039: 0039-doc-update-partprobe-manpage.patch -Patch0040: 0040-partprobe-remove-partitions-when-there-is-no-partiti.patch -Patch0041: 0041-maint-use-AM_V_GEN-to-cut-down-on-build-noise.patch -# Won't work with tar.xz -#Patch0042: 0042-maint-regenerate-.po-.pot-files.patch -Patch0043: 0043-tests-cleanup-losetup-usage.patch -# This causes builds to fail, it sees the build .git and switches on -#Patch0044: 0044-build-default-to-enable-gcc-warnings-in-a-git-tree.patch -Patch0045: 0045-libparted-refactor-device-mapper-partition-sync-code.patch -Patch0046: 0046-libparted-remove-extraneous-blkpg-add-partition-ped-.patch -Patch0047: 0047-libparted-don-t-probe-every-dm-device-in-probe_all.patch -Patch0048: 0048-tests-make-t6003-dm-hide-work-reliably-on-F17.patch -Patch0049: 0049-doc-1MiB-alignment-is-not-enough-for-cheap-flash-dri.patch -# Won't work on tar.xz -#Patch0050: 0050-build-update-gnulib-submodule-to-latest.patch -#Patch0051: 0051-maint-update-all-copyright-year-number-ranges.patch -Patch0052: 0052-maint-avoid-new-warning-error-with-gcc-4.8.0-2013010.patch -Patch0053: 0053-dos-improve-MBR-signature-generation.patch -# Won't work on tar.xz -#Patch0054: 0054-bootstrap-update-to-latest-from-gnulib.patch -Patch0055: 0055-parted-fix-EOF-and-ctrl-c-handling.patch -Patch0056: 0056-tests-t6003-dm-hide-don-t-hang-on-exception.patch -Patch0057: 0057-gpt-Revert-small-device-commits.patch - -# XXX Locally modified patch to apply without date changes -Patch0058: 0058-libparted-handle-logical-partitions-starting-immedia.patch -Patch0059: 0059-libparted-fix-gpt-end-of-disk-handling.patch -Patch0060: 0060-libparted-allow-some-common-errors-to-be-ignored.patch -Patch0061: 0061-Revert-linux-commit-do-not-unnecessarily-open-partit.patch -Patch0062: 0062-libparted-avoid-disturbing-partitions.patch -Patch0063: 0063-Fix-test-compilation.patch -Patch0064: 0064-GPT-add-support-for-PReP-GUID.patch -Patch0065: 0065-libparted-make-sure-not-to-treat-percentages-as-exac.patch -Patch0066: 0066-bug-15591-PATCH-libparted-handle-i18n-gpt-partition-.patch -Patch0067: 0067-Fix-help-text-for-disk_-set-toggle.patch -Patch0068: 0068-libparted-copy-pmbr_boot-when-duplicating-GPT-disk.patch -Patch0069: 0069-tests-test-creating-20-device-mapper-partitions-8031.patch -Patch0070: 0070-libparted-use-dm_udev_wait-698121.patch -Patch0071: 0071-libparted-preserve-the-uuid-on-dm-partitions-832145.patch -Patch0072: 0072-tests-Make-sure-dm-UUIDs-are-not-erased.patch -Patch0073: 0073-libparted-don-t-canonicalize-dev-md-paths-872361.patch -Patch0074: 0074-tests-rewrite-t6001-to-use-dev-mapper.patch -Patch0075: 0075-libparted-Add-Intel-Rapid-Start-Technology-partition.patch -Patch0076: 0076-libparted-Add-UEFI-System-Partition-flag.patch -Patch0077: 0077-libparted-Recognize-btrfs-filesystem.patch -Patch0078: 0078-tests-Add-btrfs-and-xfs-to-the-fs-probe-test.patch -Patch0079: 0079-tests-Restrict-gpt-header-munge-to-little-endian-sys.patch -Patch0080: 0080-libparted-don-t-require-a-system-id-string.patch -Patch0081: 0081-libparted-sync-partitions-16.patch -Patch0082: 0082-ui-switch-to-new-style-readline-typedef.patch -Patch0083: 0083-libparted-Fix-check-for-backup-header-location.patch -Patch0084: 0084-libparted-Use-common-function-to-calculate-PTE-secto.patch -Patch0085: 0085-tests-Add-emit_superuser_warning-for-gpt-tests.patch -Patch0086: 0086-tests-Use-msdos-overlap-to-setup-t0283.patch -Patch0087: 0087-testing-Use-little-endian-packing-in-gpt-tests.patch -Patch0088: 0088-libparted-fix-several-integer-overflows-with-dvh-lab.patch -Patch0089: 0089-tests-Use-force-for-xfs-in-t1700-and-a-larger-file.patch -Patch0090: 0090-tests-t1700-change-count-to-seek.patch -Patch0091: 0091-libparted-remove-last_usable_if_grown.patch -Patch0092: 0092-tests-fix-t1700.patch -Patch0093: 0093-tests-fix-t2310-dos-extended-2-sector-min-offset.sh.patch -Patch0094: 0094-Fix-filesystem-detection-on-non-512-byte-sectors.patch -Patch0095: 0095-libparted-add-support-for-implicit-FBA-DASD-partitio.patch -Patch0096: 0096-libparted-add-support-for-EAV-DASD-partitions.patch -Patch0097: 0097-libparted-mklabel-to-support-EAV-DASD.patch -Patch0098: 0098-libparted-Avoid-dasd-as-default-disk-type-while-prob.patch -Patch0099: 0099-libparted-mklabel-to-support-EDEV-DASD.patch -Patch0100: 0100-dasd-avoid-usage-of-uninitialized-data.patch -Patch0101: 0101-Update-NEWS-with-new-DASD-features.patch -Patch0102: 0102-GPT-strings-are-UCS-2LE-not-UTF-16.patch -Patch0103: 0103-libparted-fix-fat-resize.patch -Patch0104: 0104-parted-don-t-reload-partition-table-on-every-command.patch -Patch0105: 0105-libparted-don-t-detect-fat-and-ntfs-boot-sectors-as-.patch -Patch0106: 0106-libparted-remove-old-partitions-first-before-adding-.patch -Patch0107: 0107-libparted-remove-all-old-partitions-even-if-new-labe.patch -Patch0108: 0108-libparted-fix-loop-labels-to-not-vanish.patch -Patch0109: 0109-libparted-don-t-create-partition-on-loop-label.patch -Patch0110: 0110-partprobe-do-not-skip-loop-labels.patch -Patch0111: 0111-libparted-give-correct-partition-device-name-on-loop.patch -Patch0112: 0112-libparted-don-t-trash-filesystem-when-writing-loop-l.patch -Patch0113: 0113-tests-test-loop-labels.patch -Patch0114: 0114-libparted-mac-support-sector-size-512-correctly.patch -# Won't work when applied to the tar.xz -#Patch0115: 0115-gnulib-update-submodule-to-latest.patch -Patch0116: 0116-maint-remove-doubled-word-s-on-on-on.patch -# Won't work when applied to the tar.xz -#Patch0117: 0117-maint-run-make-update-copyright.patch -Patch0118: 0118-tests-Add-ntfs-vfat-hfsplus-to-t1700-probe-test.patch -Patch0119: 0119-tests-Use-mkfs.xfs-to-create-files-1101112.patch -Patch0120: 0120-maint-fix-make-syntax-check-nits.patch -Patch0121: 0121-tests-avoid-false-positive-failure-due-to-symlink.patch -Patch0122: 0122-tests-use-test-s-operator-not.patch -Patch0123: 0123-libparted-Fix-part-dupe-with-empty-name.patch -Patch0124: 0124-tests-check-name-when-duplicating.patch -Patch0125: 0125-Fix-python-test-scripts-for-distribution.patch -Patch0126: 0126-parted-add-resizepart-command.patch -Patch0127: 0127-tests-excersise-resize-command.patch -Patch0128: 0128-libparted-Add-support-for-partition-resize.patch -Patch0129: 0129-parted-make-_partition_warn_busy-actually-a-warning-.patch -Patch0130: 0130-parted-Allow-undocumented-commands.patch -Patch0131: 0131-parted-Add-stub-resize-command-for-backward-compatib.patch -Patch0132: 0132-Document-resizepart-command.patch -Patch0133: 0133-tests-fix-t9020-alignment.sh.patch Patch0134: 0134-maint-correct-a-POT-file-updating-rule.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -210,14 +66,14 @@ Parted library, you need to install this package. %prep %setup -q -gpg --import %{SOURCE2} +gpg --import %{SOURCE2} %{SOURCE3} gpg --verify %{SOURCE1} %{SOURCE0} git init git config user.email "parted-owner@fedoraproject.org" git config user.name "Fedora Ninjas" git add . git commit -a -q -m "%{version} baseline." -git am %{patches} +[ -n "%{patches}" ] && git am %{patches} iconv -f ISO-8859-1 -t UTF8 AUTHORS > tmp; touch -r AUTHORS tmp; mv tmp AUTHORS git commit -a -m "run iconv" @@ -225,7 +81,7 @@ git commit -a -m "run iconv" autoreconf autoconf CFLAGS="$RPM_OPT_FLAGS -Wno-unused-but-set-variable"; export CFLAGS -%configure --enable-selinux --disable-static +%configure --enable-selinux --disable-static --disable-gcc-warnings # Don't use rpath! %{__sed} -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool %{__sed} -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool @@ -298,6 +154,12 @@ fi %changelog +* Mon Jul 28 2014 Brian C. Lane 3.1.90-1 +- Rebase on upstream Alpha source release +- drop included patches (all but one) +- add Phillip Susi's GPG key +- make sure gcc warnings as errors remains disabled since we use git for patches + * Mon Jul 14 2014 Brian C. Lane 3.1-29 - Rebase on parted master commit 081ed98 - libparted: Add support for partition resize diff --git a/pubkey.phillip.susi b/pubkey.phillip.susi new file mode 100644 index 0000000..3e02657 --- /dev/null +++ b/pubkey.phillip.susi @@ -0,0 +1,153 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- +Version: GnuPG v1 + +mQENBE7n3q8BCADW6Ejug3TeJn21ri5Pnqo7AraXyOhSWeatq377kbF9fJb+bd4l +hhcWqs9BBCMcOrMdfDgAU6cP+TSNe5SBBPt89d0YZ8WH020eg3WkxXeph29wZyLj +2HdxTMpZVv5p6QL1ksRmbnsToiJvXT24ydjLG3BTl+TAEDXuppPq0AlEYqkvD9fY +Sqad1s064IppHQZhYVgmcEHOHt0vY66QW+UfwSI+GpkaXULlDS9WAphgWXrUoodb +tC283pZUcBAio54uENUNT96ChzdlJ/9eyDRMjEhyL42AmazPVKgwZdLlrPG0iodD +evxvsDbIgu0acGAeSjvt1tWgI+F5TJDeYfxfABEBAAG0H1BoaWxsaXAgU3VzaSA8 +cHN1c2lAY2ZsLnJyLmNvbT6JATgEEwECACIFAk7n3q8CGyMGCwkIBwMCBhUIAgkK +CwQWAgMBAh4BAheAAAoJEAFfTdSnD7cFcZoIAMzUUmRQEjdV6Y9t5H/geCUlRpKA +YLyf5mLvp6+9d+Sj8Jr80Gqdaf/+PCPx+s6OaVivwdrS/RKGQCJqlRhYUZfhhcSK ++LY8JhK7tXVqjTSCKZ/eExzHyNSRUS2CIS0bfFRaBKmWUnnz4GUjEZdEV7RsgaxQ +tAB2ZhJ3podyXNuakVhOmumzMBKJOKYmVv0+Z/t0kh3eFCghS8X7xCmunswUvlUW ++OxV6nlg/MUP6L1abHPHgUkapM8rKYEI15V9iZL0xgJkUr973u4msvMzapKqtrxX +QshLoCbLKeOQSOlNuyjPQCySFMeZeUQIORWLX27JNTq7ZBnRJU6SQA5cw92IRgQT +EQIABgUCTuffOAAKCRAnhRyIiz5e4lggAJ9mZBuaj7qRNq6TfxzoKVKNehdzhACf +TCC7CTp4Fd83EHmPOLhRUIvn9UeIRgQQEQgABgUCUdi5zwAKCRDbBAoTo9e5vEkj +AKC+vVlhENdPek4psgGXEgIsxYzS1gCfYSYPMcIMwkFAq9A6RmWTpKKDhyGJAhwE +EAEIAAYFAlHYdmEACgkQF2LgInA0z4TCkRAAn05uE5/gBjFdraGob6IoLV8yDQQi +sJVLvNg037/ZQCAJkJouWaT4F2NtBzRaZNK9Qdqq8kFWF2KxTgxWtcpSFSzfGPuK +wqx10dRlVa5BoT8yFLDO3pq/FQnmKdKxPbi3xVhcfNXaaXSRm4XoSa1/E6CMdU2k +TZdtfUTnn7pxhzNrHXgjqxO4ZEq3yLSK/yfxkECgDGCh/kS5cj6PxlvMXvLBQfeS +/cG7+PDlgSByogS2gsnU+cXlgLcR3fOK7Q8CLUhHnKgloA2fEuYATDt5jfZF3iW3 +VJgBmmHFe/zS4fuJaFeEaW2EjMhZmPj8iRWGH8B9/HODRKX9t0+XVMoo1M8T2Xxd +Q6cdh7VWIGJQ6b+6n2T/uANAn1BKvwVcTlGgu0/WMLS3oYOFB0UeJq84kugpi+hu +R40NRK2O7VaT39Jj78qvLYdun3CNXyWP745hX5uuhTSpxb1L8SBqQ/RTWY0x/lS6 +77/Non/Iv85xlQputl6orT4RE/rZElvh8DwhX+3dV7RdUqmC+pc0ssOAC2h8LzcM +UvIolgV+58OxEVqasZQKmgbKzvrlbwpxOvWzYyUMRF6i8RrB/9c4e/eyEKEHQtqr +c0+MWcBIpo7SJufXglWcF5qtrAgce0jbmzYMACjb4jv2HNnYGyYRJXnuUduOOCAl +8mz0A9gLy1Leii+JAhwEEAEIAAYFAlHYubsACgkQyfxBuPmMZs8R0hAAqd99YXpU +55om9BMA7fxup+6WEA3Kb8hIIvVGchCoc0MLtq3uZ1rJLwPK8xHCGObyrVW51SWg +u8H1ddFElFm3BCje+uoQK1b3WPmBu1s4YEjRR9qmL+EyFjog1OHKkFfWKiplu+6L +zVEbUCwg3CaiVPjbxbVNjaSmpqL5ImtS8UfwGXAJx4F/QahA88fxd3sV9ejv/bG+ +YuT0etVcnU2gOkBNEjvFi3NzZWVMLnAEeExQ62TurzhoMKLv2CXgvArAfk3ZVHF9 +M8y4+Qoaa2SzMiESLU8Wq5wP1zaMjbQZi+e5QlWES3M2qAZqAiHO727VmYepfo/F +TFuN69R5Ic6ql7ssI8K3s5NgVvIwtj0q8gRttciozxGBpW4F4j4Tz98DDy3UVkb+ +K0jf2Mz98ph7FMfCoyh5ketLiEgyYFfDMoNK+qo5JiVrycDuSnibx56sZhwmgxpI +X0ta2F8ZFW93fnIBfB2whVbbkTpw118eU4vOyJjwFAzMf9qhSn5zGZTh6g8MZhb3 +z9x+E6CRXWe40IYjOkx+0XbQkCLcTzwIi9WDzPkCGb9KXLmGvHErAn37B51HVEh7 +9vDI5ZSBlj7uk3hKHPEwbAiqExW/RU88vkSI6iDYWenEu05/EBmP71whpLaAPOVJ +7yxPKa3IuHPDOmYlFBl0/epFkwq820Zi+vW0H1BoaWxsaXAgU3VzaSA8cHN1c2lA +dWJ1bnR1LmNvbT6JATgEEwECACIFAk7n31kCGyMGCwkIBwMCBhUIAgkKCwQWAgMB +Ah4BAheAAAoJEAFfTdSnD7cFKYEH/1z0AARRSyCiB/FnutwNQDxkfZdDpMIJpoXF +C65il25uzoWw2ejZRwQ5Jo9B8nyyMryZeRviFXOi+Sdfi9Q2lRN0Lbt3z6H2LD7v +NzV8Z9fe944uHsEQzU2pso1OOLMvC5FAdL942tugO9o8VNLuS+gf2W8gs28XJOx2 +HdV6wvT3aqsVGGEYJbyZ9qQvvb3xkvs3xC3xIvHLknOUB73tEhoLCtVohD6xiRVc +qF8meKw/Pd5NK+dbRCS6zLRtdAVR6bVbnwgM1TJWPAHtg8dk4JsiCHtlOBPtiCjZ +n9ZLbEQ009N669J9JYiqqmM3wZTi/LVWRvUtvdTPk0PB8JjdMM6IRgQQEQgABgUC +Udi5zwAKCRDbBAoTo9e5vAwcAJ0WPMMJd02icRSZJtfFN2L5/5AX5gCg4px8TyLK +whHHkhI7A77lm1KvGO6JAhwEEAEIAAYFAlHYdmEACgkQF2LgInA0z4S/lg/8CVje +5q3Zsz2d5UErAM5Ade7zHmeCxUn7MaJYhLtp95BvEmVdlazntK6C3/TK3qdflDKq +oQAkovHV5qmpKBqLGYUEOH44N2Px9y8tKe9nx5ppMYBb8+dwhdQ8uSZI7wdUmINZ +ym4ZH0+bLokg4vaDjKkSE4aR87m9auzdKj+VGVKUy8TOIdsL4ItFkipVqTpA65dd +tDIHHk/xF3t8Wb9hzhDGM1e6B/sXMOCa5PK0VCtE1nwpg0nseS3vRLR3/xGKqnrB +j1ShnoTZehlxCou50HaTKxAnK89UVugelYnf12oftDaHhJ4dbyhmsZwEPV6VO7Qq +mUMDj0adw18VETFtT+NDkN6AIRrU7AAHDaw0tU08gJ3YzFx+P2dnQ1OgGYLsomG7 +5uV5O6FAagYvWmHDtYL80TEjWgzfItotGr7roT0liTi+YqyKVxFHMwIL/hcpxt7Z +nVfqgC7dZG/ovwhnfk1Sm60dAeIGFgdyKrFafEZa9NvKcTmCKdlJ3N5l47WM+3Yp +3E4Z687XaggidWaOGloG4mCL7nGxCTZtTCNlynmzNVnvknmmTm6VlI2NmqAF3XDA +XWa7/SFfCIyz8WCKgeAkM5ZumhwSUjHjV72XdFulJUrU4zJstz0kfBmAYNI11HEH +36iZdbujt4Pxn+tHS13RRFEX/yKqcSZH36ZnRxuJAhwEEAEIAAYFAlHYubsACgkQ +yfxBuPmMZs861RAAmSBnFNLIGCcB7rQc8mGfkSKt46PvleOqEnIOXTiFHixPVvRx ++xigusyzseu6lBNCSYLAq2q+rfsj6lfNHE4vUJk/vVc2QruCRVYPkowLPgde20n3 +eu44/KODyxHm0bds17IkrAsPlwQixQ/YhuciiMzTI9+zDTBj5nE6C+VkiBssFluU +gag1UXH2vU6e3ZqOizFVxtpiAwY7iz+4eOBIJsyyUUTT9b6lGn/OukMpjTZ2IZnR +gY+fpUCCNsWv/V4y0+q6+X2a2e3alE7+VT/4xO8bqlQu3rn3rz4MW2+IJ9LlHAIQ +WdO0SDAiVFVZDrM+FhNLxMtsQs5GnmhZCH2tYvIbRHqWiMiQERm28De+8zxcXdkb +lPmDVmBctgMFGPiI/9Xlf+33Zu/DYPsiNde7rISP6EZi++YaNdZAYmb/UFffxtFX +twRFi2/61AeULXAR0hB5JM8V7gAt1xEfpKJgb02B21wg+MaKYXpttUFU73URGNL6 +vq7b4Z4TrLm2IVcnl2nINawsMm/pMvIS26fcTrsiPrPaOZJuvGoA5JR1PkGbo+uE +TuXqk/sImwlIHamzvPU+qaXvNIGQZ3YBMeLo+nx0Tzyws2Jhc7ohlpyNyO2prXxc +cg/Fc6BEWX/su71ScOz9e+JpXtSexZDFufr93tVXDKAZ7sl/oXKhF/1ZG7K5AQ0E +TuferwEIAKlXsAHCt+n1F6mc4/E7gG3/39HJobpmtu42bnkEmNFCf3Vl1oZeCnrC +Nh/z2Ag7g/tegWrkmubPnRskd/hpwtvmimxkZVuIUzaE1UhkLiJfufgyIidZ7X0e +vjbX9NfYjn3ZY3bG1jF7rh+FVmW8dPSn5DOhSU6CSCdrpKGG4YriIw7Uoti4nj5C +QuVF8J0tBMXQLBXhwboaIvA5vvb59WA8e9fGSHhZMcFjPytUC6LK1WEnaBhhAEGi +g5/Ww2Hs/LJaQfbRo4yeLAYlQUiS6IobX0a8ZIN/alsz0qSIhLzUJH6OzHkZz3Xr +ScgM1a5gjIvvpmrUd4J+GaysJsgAfvkAEQEAAYkBJQQYAQIADwIbDAUCTufwEwUJ +AeGCIQAKCRABX03Upw+3BSLwB/9vr2gyiGAOg+1Ba21xmnNs7xjAuPxrlslWkzCL +h8+wLaW7+X8Sg5lT+F15NEPIUFU4XdmGVBmNBiedeWesZRaOz+plsjP7esbE8bPg +X/2Rr8sVHiT6kF3TLNOYmy8gVEBMLLuCmOUlNZrlIOH4D6Ubb2bzgg7V/+asDyfR +AlK0yhUxTK99egMM3qvVUlnGAMmIXvV3FbLLgcDb2HFThu5Cez9dWxDtHqPFNTbT +EjxZ/+tNmNwYSOir7ZuJHZjaIcXzjlWfLbGPVRVMnTGkxol/l4gagYDcV3lnYjH3 +ApwAM7AcRbX0HnL7pgKPNU+tLGCu9htOAK2Cst0Psw+RwRmHiQElBBgBAgAPAhsM +BQJQwADGBQkDwrWhAAoJEAFfTdSnD7cFhe4IAIvNnPdYSD7v9SbJ1Dabcx9djkF4 +xwWRnpSQHV9zn6SiKIJcCEfjIiffzX400+UoQzEHbsl3C/V5boMHoLX+Mj7+7OL2 +CWm49jzLN29knJ9vS4GTaRKLVP8ge+f8P24kJedCniSLk4p/PwIL1TpedYvlU/4J +YNhbJSQY4IfLuC2Hm0HB08mxtd2aa5ZK7apjGFajpz7vawuuHy+yciXkt08E1tVT +kXUpJXohoaXQ/GXMTFlwxCUVGMIc4ehleQKyIW5Wo2NrKSJQvZRKc/TYGgRH5FL7 +bwzyFjMcRj36Z7YVAgqNTHkwdvHV41VLqfEiJgcW3PKGNwCPHP4EUIEPBTW5AQ0E +TufzzwEIAN6VDBHV9OIq9DyxtoUwDrIlu+YTdi6LWuEA5vZqzw97tjp94l8EfSxY +gDhOL4vvR8LxY5IkUSDGefuSLa8Do82U51ksR/KkVPhQmZRKCU/7KTFe2oluvyaV +N0pmHriT+lTNF8/OptGHutS2Cc1dffajDAdWC8X5eXio1tXfFYE8dr7W9hMoTelW +LSA1rwEmfLWaeXvpqTmOHUBPYJjVdLIQ12rWXbAk0snu6kwznbSXy7Pnp3NZc0r8 +ySDsjO3x6eLiOMcckFBn+8YS9X7ktzNl5+iLnTAx+Nvwbw9spMDiecLOFrSanvZz +zcaj07yvJGX8zQc8/t29S4kqqp34uBkAEQEAAYkCRAQYAQIADwUCTufzzwIbAgUJ +AeEzgAEpCRABX03Upw+3BcBdIAQZAQIABgUCTufzzwAKCRCawTpU+p7u+TGgB/44 +iovlwuH28zFKHFirLzB5OFB4xc8+dv2hj24cl+VIkPXFRKt4AuZ3iWI6bn075Gm9 +r50FejQktm6E5Anh5f/O7xYDA3bFM6Cig/0czYY6easI1TTwEk5yYgKnTF0BM490 +bNfCZf+S274YzDISmHfviYyzLDcwoqgHGUZlZb6P9rk5skUITA69iTLLKLgIaDON ++YcVXtoFG9yFBK7KXbNs6qxBz+vgIVpYrk+vHD4rxXVQLO6+bn9XksCmrvJ6hvur +b3lI/xW+hraHdM6EafI2NWbo29ntZ3S7vwNIwoXQbWjhZqqrLLfq8cwR7KFeRtPJ +4DfvQXXVtOSrVFd7ZVT57gEH/jOD0l3jym/4OHOdKUIluvFcFH+hN33nwAhgXdUt +GPbQhBu9iXuW0+rFi8ZjYsnmMMNIV2JBQ3rhwqiEsXJeUkZ5SyPeKkx7MTSgHq7T +vAmNk+R2PkbpEm0KLEBHLBJtHbmeTyTdZDm0usKDUrfAYPvkcgA5+7QGavoGAUCr ++u49s4bxsjq+Cd9IemwtXTU6vP4RW4UWuqGQ/LWYDfYwBO5/ZXSLlUvZ/gzYXgq4 +pcOBhnbTqJs9ok+K7tztVvCApKLMK7ab7t1y6ZmflvWaVAR4pgneX3uS5qU9V4wn +mBhrOVZHQXkMGHcAyya0cABx1Wg3nqasUZfykvr43a2Wd1uJAkQEGAECAA8CGwIF +AlDAAN8FCQPCoIEBKcBdIAQZAQIABgUCTufzzwAKCRCawTpU+p7u+TGgB/44iovl +wuH28zFKHFirLzB5OFB4xc8+dv2hj24cl+VIkPXFRKt4AuZ3iWI6bn075Gm9r50F +ejQktm6E5Anh5f/O7xYDA3bFM6Cig/0czYY6easI1TTwEk5yYgKnTF0BM490bNfC +Zf+S274YzDISmHfviYyzLDcwoqgHGUZlZb6P9rk5skUITA69iTLLKLgIaDON+YcV +XtoFG9yFBK7KXbNs6qxBz+vgIVpYrk+vHD4rxXVQLO6+bn9XksCmrvJ6hvurb3lI +/xW+hraHdM6EafI2NWbo29ntZ3S7vwNIwoXQbWjhZqqrLLfq8cwR7KFeRtPJ4Dfv +QXXVtOSrVFd7ZVT5CRABX03Upw+3BTbpCAC8jKw2VlNIoX6LLpwH5ZvDQy1MIdER +t3f6FZ2btiCgfBYF7qIGwcOrNqZn0sG/znOE1j0G8jvhaR74GfXW1NNz3vOs7MX+ +TuDoGOeqXwRN/GL9YJs9T1qm6RVY28Ajs9ikPl5HOEy2PowLw8MuViktdIHLwcdj +Hxy14Rhw7E8Yp4FYyzWuUgSDa4XhdeoTtdHTioed+q/x60rT7kEFM4fBbb7asBRs +G0B3ZVAu4gKVtu1OeONn+biwbIDj/igV+NumH2AXOuZ7olIHSox3Nm6Ea4huvkAA +xXTW5Jfr6yBpsP3m1SXPiB5lJjaqp35nQ/CeTGZrJHPxu2G1K8O/cOc3uQENBFKU +I2UBCACtz9PPTL8MdfOAt/8BI5VH274Qbahh1rb4j1W/CAvuGUYLg0oJ2A7OnKNb +mO58I0huUCZ5f9ijPidU387RYvL8cpRZDy4aN7uVsSI/GXXTXJIY2VuVv8alRhFu +517smRxVG/WKqpWCPuNr04njwSe7Qw8E3n6RC0w11i2DvQL8RVwseffnFl5+1f7t +ZKb7K64AuBtVKGMvJqC02QvOdfBSLFE3Y3PzvhV34RnKKsKJuKRTvTi/oqzJyk9l +iFdf22SANqnB8HZL5mwCxqkjbkKTNlTBPaqp56U94a6xCkjRmZzeGvmXIXbntBcj +NxhOG0h9nNCEa7WVu4uKWC+L/LS/ABEBAAGJAkQEGAEKAA8FAlKUI2UCGwIFCQHh +M4ABKQkQAV9N1KcPtwXAXSAEGQEKAAYFAlKUI2UACgkQjkWgIjNIqvAllAgAllBe +IN1KEsJIAroMNnzx8tsNz9u9KxevvM/PRNKcpgniciJt5A1yHhO9rfKmgDoiz+C2 +hK5kLqG4ZC+WXgof5KQTMOgTFtc9B8VU7FaS1w4gO8kLXLswHMsHmZNOaCTdr23s +c9Rabf1OtJEQzvjkizaT4izWVWKtNZ1qYy6zzPAFq7u08svILbHg2sXMQacRPx4r +CA44RVfZ+emhunAVvQAbyRRoO4kmRbGSSyTsl/79AMqIygWpTu8ZBNevZda5Yf5l +bvUo1jmGdNxiDlMtpVHx1zjK04J5PaLZIvTEfqYQztGqOPOUfvTJeVeXr2uCci1D +9uMeGp4fweu5jhOnTgjyCACqPhh2csd/5aSm0ZksEMr0tzi+2uM6nXIVlKLNqAoH +4khBEcxhlQgCHB/lrOY3MxiX0y93d4PywdLAwqA0eeEBPDR1Bjh8hxdDWDz5Ijoy +OpxVbTxEJOZSz61K5pbPVh2mOpjf/9kpx6M4+JslKXwmH4hqK8n/o1C/bsfIOavb +CHAeMKhrsUlU/78xDnWrtudFiQG+XDyhS4tDeoX1wXjOKDFJAED8jNGDjUnu4bwt +eCaFPqLZmQWpHQKLF00fIJDytHoQcE9KiveuIYIGZcfLjazfjSzpE0IQ/+pgDoo/ +0sv7ToDAToKmbQerOic8bE4HJ9HpVqjewatVWs1vGG2GuQENBFKUJRoBCACTkbTe +Ep8+bZOHWhktBezImhWOXVvwkbGKguphG4KHZp2m15oe25POvmoEqpk45ZtQNitg +sZnj8cKT+U8cv4W0TaxcJ/dYxK4VTG6Gjj3gQSu0t0H5R0mDA1vCHTVdQRCD8W+h +bO6zModU2XFdaw7qI2un9TufQ48L5GYYLl5n0yYdGqqjVWh+l3BdY19evfDAGSZw +gbzKWlOtyfRa5EdK7AWJx1haoYwGbMt7gAS7f4iR18z3RuKLB394gGxWDowRu43D +Z9QC9O9borbfDZYQGrE4W3IeTFvjQn8wxU/vnhqtL1FiYVEpdB9d9cag8bLst4An ++9a9KSsMvGnAaBGHABEBAAGJASUEGAEKAA8FAlKUJRoCGwwFCQHhM4AACgkQAV9N +1KcPtwVJhQgAxaqhS1rUAVg+7XOuEAsVdyaBZTtd2T0tNv5io7PI1u20sLJW/w+2 +aVNa3VI4ZTP9Z+GamiclIZ7Vs7+S6ZrF3BGR57wT9aNcxET28Z9ftt9rj3CKq27d +lxt6hcdCrDOzoGDi6C2TszMgWJLfy4ITLd4ziuZLqS+Z6HACk6GPHyuwKgzC90+I +S6Oef4tJ00ageAtJpSo0/z/nd1rVbPDHK411NjllWcW9GVdEfdyNwcHi32zSaQoL +GKa6wfkTOdpz/Q4zPiW8gv5/uK6RArZxy3PZ2F1njw14IqGARABpve/YIqzCypv4 +J06Mmq/4oTsyCpbhLO1MtYvb45vm0/qStw== +=/VGh +-----END PGP PUBLIC KEY BLOCK----- diff --git a/sources b/sources index c8a754d..eae9d52 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -5d89d64d94bcfefa9ce8f59f4b81bdcb parted-3.1.tar.xz -1ac086e39d63d3f37f6da1d85e4829a3 parted-3.1.tar.xz.sig +48a72b4155ad0e8ff05f7bfdf78c3b79 parted-3.1.90.tar.xz +2f1e2fd988963ad0a5c0361d88f5ef50 parted-3.1.90.tar.xz.sig