From e13022c01a2cd944e28c61827c96b0a37f4eecf0 Mon Sep 17 00:00:00 2001 From: David Cantrell Date: Wed, 21 Mar 2007 15:02:34 +0000 Subject: [PATCH] - Do not translate partition name from disk label (#224182) --- parted-1.8.6-notransname.patch | 39 ++++++++++++++++++++++++++++++++++ parted.spec | 7 +++++- 2 files changed, 45 insertions(+), 1 deletion(-) create mode 100644 parted-1.8.6-notransname.patch diff --git a/parted-1.8.6-notransname.patch b/parted-1.8.6-notransname.patch new file mode 100644 index 0000000..5fdf10b --- /dev/null +++ b/parted-1.8.6-notransname.patch @@ -0,0 +1,39 @@ +--- parted-1.8.6/parted/parted.c.notransname 2007-03-13 13:01:09.000000000 -0400 ++++ parted-1.8.6/parted/parted.c 2007-03-21 10:50:35.000000000 -0400 +@@ -1429,7 +1429,7 @@ + part->fs_type->name : ""); + + if (has_name) { +- name = _(ped_partition_get_name (part)); ++ name = ped_partition_get_name (part); + str_list_append (row, name); + } + +--- parted-1.8.6/parted/table.c.notransname 2007-03-13 13:01:09.000000000 -0400 ++++ parted-1.8.6/parted/table.c 2007-03-21 10:51:31.000000000 -0400 +@@ -191,7 +191,8 @@ + len += wcslen(COLSUFFIX); + + newsize = (wcslen(*s) + len + 1) * sizeof(wchar_t); +- *s = realloc (*s, newsize); ++ *s = (wchar_t *) realloc (*s, newsize); ++ assert(*s != NULL); + + for (i = 0; i < ncols; ++i) + { +@@ -199,6 +200,7 @@ + int nspaces = max(t->widths[i] - wcswidth(row[i], MAX_WIDTH), + 0); + wchar_t* pad = malloc ( (nspaces + 1) * sizeof(wchar_t) ); ++ assert(pad != NULL); + + for (j = 0; j < nspaces; ++j) + pad[j] = L' '; +@@ -211,6 +213,7 @@ + wcscat (*s, DELIMITER); + + free (pad); ++ pad = NULL; + } + + wcscat (*s, COLSUFFIX); diff --git a/parted.spec b/parted.spec index 55e03d8..62bdf69 100644 --- a/parted.spec +++ b/parted.spec @@ -4,10 +4,11 @@ Summary: The GNU disk partition manipulation program Name: parted Version: 1.8.6 -Release: 1%{?dist} +Release: 2%{?dist} Source: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.bz2 Patch0: %{name}-%{version}-warnings.patch +Patch1: %{name}-%{version}-notransname.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) License: GPL @@ -37,6 +38,7 @@ Parted library, you need to install this package. %prep %setup -q %patch0 -p1 -b .warnings +%patch1 -p1 -b .notransname %build %configure --enable-device-mapper --enable-selinux @@ -84,6 +86,9 @@ exit 0 %{_libdir}/pkgconfig/libparted.pc %changelog +* Wed Mar 21 2007 David Cantrell - 1.8.6-2 +- Do not translate partition name from disk label (#224182) + * Tue Mar 20 2007 David Cantrell - 1.8.6-1 - Upgrade to GNU parted-1.8.6, summary of major change(s): a) Revert linux-swap(new) and linux-swap(old) fs types, it's