fix end input usage in do_resizepart
(cherry picked from commit 07edf3bee78629ea80c070077007f7cde7139c2d)
This commit is contained in:
parent
8543d9767c
commit
cba57d6cc1
34
9002-Fix-end_input-usage-in-do_resizepart.patch
Normal file
34
9002-Fix-end_input-usage-in-do_resizepart.patch
Normal file
@ -0,0 +1,34 @@
|
||||
From ca845aeeddb17343c9289816833ca352f7c0d87b Mon Sep 17 00:00:00 2001
|
||||
From: "Brian C. Lane" <bcl@redhat.com>
|
||||
Date: Tue, 23 Apr 2019 13:52:25 -0700
|
||||
Subject: [PATCH] Fix end_input usage in do_resizepart
|
||||
|
||||
It needs to be set to NULL, since it may not get set by the call to
|
||||
command_line_get_sector
|
||||
---
|
||||
parted/parted.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/parted/parted.c b/parted/parted.c
|
||||
index 9dcdb05..df0c7ed 100644
|
||||
--- a/parted/parted.c
|
||||
+++ b/parted/parted.c
|
||||
@@ -1545,6 +1545,7 @@ do_resizepart (PedDevice** dev, PedDisk** diskp)
|
||||
PedGeometry *range_end = NULL;
|
||||
PedConstraint* constraint;
|
||||
int rc = 0;
|
||||
+ char* end_input = NULL;
|
||||
|
||||
if (!disk) {
|
||||
disk = ped_disk_new (*dev);
|
||||
@@ -1565,7 +1566,6 @@ do_resizepart (PedDevice** dev, PedDisk** diskp)
|
||||
|
||||
start = part->geom.start;
|
||||
end = oldend = part->geom.end;
|
||||
- char *end_input;
|
||||
if (!command_line_get_sector (_("End?"), *dev, &end, &range_end, &end_input))
|
||||
goto error;
|
||||
_adjust_end_if_iec(&start, &end, range_end, end_input);
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
Summary: The GNU disk partition manipulation program
|
||||
Name: parted
|
||||
Version: 3.3
|
||||
Release: 4
|
||||
Release: 5
|
||||
URL: https://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
|
||||
@ -29,6 +29,7 @@ Patch0000: 0000-Switch-gpt-header-move-and-msdos-overlap-to-python3.patch
|
||||
Patch6000: 6000-add-support-of-gpt_sync_mbr.patch
|
||||
Patch9000: 9000-Add-extra-judgment-for-a-partition-created-success.patch
|
||||
Patch9001: 9001-bugfix-parted-fix-failure-of-mklabel-gpt_sync_mbr.patch
|
||||
Patch9002: 9002-Fix-end_input-usage-in-do_resizepart.patch
|
||||
|
||||
%description
|
||||
The GNU Parted program allows you to create, destroy, resize, move,
|
||||
@ -113,6 +114,9 @@ fi
|
||||
%{_libdir}/pkgconfig/libparted*.pc
|
||||
|
||||
%changelog
|
||||
* Tue Feb 9 2021 Zhiqiang Liu <liuzhiqiang26@huawei.com> - 3.3-5
|
||||
- fix end input usage in do_resizepart
|
||||
|
||||
* Tue Feb 9 2021 Zhiqiang Liu <liuzhiqiang26@huawei.com> - 3.3-4
|
||||
- set release num to 4 for CI
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user