Compare commits

..

No commits in common. "b893aa83b09ac425dbe88d15b633e4e50e6d7bfa" and "f8e1ee017934829ec1068668a1248edffa7eee38" have entirely different histories.

6 changed files with 2 additions and 119 deletions

View File

@ -1,28 +0,0 @@
From 5d5e76d369a412bfb3d2cebb5fc0a7509cef878d Mon Sep 17 00:00:00 2001
From: Rod Smith <rodsmith@rodsbooks.com>
Date: Fri, 15 Apr 2022 18:10:14 -0400
Subject: [PATCH] Fix failure & crash of sgdisk when compiled with latest popt
(commit 740; presumably eventually release 1.19)
Conflict:no
Reference:https://sourceforge.net/p/gptfdisk/code/ci/5d5e76d369a412bfb3d2cebb5fc0a7509cef878d
---
gptcl.cc | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/gptcl.cc b/gptcl.cc
index 34c9421..0d578eb 100644
--- a/gptcl.cc
+++ b/gptcl.cc
@@ -155,7 +155,7 @@ int GPTDataCL::DoOptions(int argc, char* argv[]) {
} // while
// Assume first non-option argument is the device filename....
- device = (char*) poptGetArg(poptCon);
+ device = strdup((char*) poptGetArg(poptCon));
poptResetContext(poptCon);
if (device != NULL) {
--
2.33.0

View File

@ -1,43 +0,0 @@
From f5de3401b974ce103ffd93af8f9d43505a04aaf9 Mon Sep 17 00:00:00 2001
From: Damian Kurek <starfire24680@gmail.com>
Date: Thu, 7 Jul 2022 03:39:16 +0000
Subject: [PATCH] Fix NULL dereference when duplicating string argument
poptGetArg can return NULL if there are no additional arguments, which
makes strdup dereference NULL on strlen
Conflict:no
Reference:https://sourceforge.net/p/gptfdisk/code/ci/f5de3401b974ce103ffd93af8f9d43505a04aaf9
---
gptcl.cc | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/gptcl.cc b/gptcl.cc
index 0d578eb..ab95239 100644
--- a/gptcl.cc
+++ b/gptcl.cc
@@ -155,10 +155,11 @@ int GPTDataCL::DoOptions(int argc, char* argv[]) {
} // while
// Assume first non-option argument is the device filename....
- device = strdup((char*) poptGetArg(poptCon));
- poptResetContext(poptCon);
+ device = (char*) poptGetArg(poptCon);
if (device != NULL) {
+ device = strdup(device);
+ poptResetContext(poptCon);
JustLooking(); // reset as necessary
BeQuiet(); // Tell called functions to be less verbose & interactive
if (LoadPartitions((string) device)) {
@@ -498,6 +499,7 @@ int GPTDataCL::DoOptions(int argc, char* argv[]) {
cerr << "Error encountered; not saving changes.\n";
retval = 4;
} // if
+ free(device);
} // if (device != NULL)
poptFreeContext(poptCon);
return retval;
--
2.33.0

View File

@ -1,27 +0,0 @@
From 6a8416cbd12d55f882bb751993b94f72d338d96f Mon Sep 17 00:00:00 2001
From: Rod Smith <rodsmith@rodsbooks.com>
Date: Sat, 16 Apr 2022 09:32:04 -0400
Subject: [PATCH] Updated guid.cc to deal with minor change in libuuid
Conflict:Delete modifications to NEWS.
Reference:https://sourceforge.net/p/gptfdisk/code/ci/6a8416cbd12d55f882bb751993b94f72d338d96f
---
guid.cc | 2 +-
1 files changed, 1 insertions(+), 1 deletion(-)
diff --git a/guid.cc b/guid.cc
index 1e73ab7..d3e4fd5 100644
--- a/guid.cc
+++ b/guid.cc
@@ -141,7 +141,7 @@ void GUIDData::Zero(void) {
void GUIDData::Randomize(void) {
int i, uuidGenerated = 0;
-#ifdef _UUID_UUID_H
+#if defined (_UUID_UUID_H) || defined (_UL_LIBUUID_UUID_H)
uuid_generate(uuidData);
ReverseBytes(&uuidData[0], 4);
ReverseBytes(&uuidData[4], 2);
--
2.33.0

View File

@ -1,6 +1,6 @@
Name: gdisk
Version: 1.0.9
Release: 3
Version: 1.0.8
Release: 1
Summary: GPT fdisk(consisting of the gdisk,sgdisk,cgdisk) is a set of text-mode partitioning tools
License: GPLv2
URL: http://www.rodsbooks.com/gdisk
@ -8,10 +8,6 @@ Source0: http://downloads.sourceforge.net/gptfdisk/gptfdisk-%{version}.tar.gz
BuildRequires:ncurses-devel util-linux-devel gcc-c++ popt-devel
Patch0001: 0001-Fix-failure-crash-of-sgdisk-when-compiled-with-lates.patch
Patch0002: 0002-Fix-NULL-dereference-when-duplicating-string-argumen.patch
Patch0003: 0003-Updated-guid.cc-to-deal-with-minor-change-in-libuuid.patch
%description
GPT fdisk(consisting of the gdisk,sgdisk,cgdisk) is a set of text-mode partitioning tools.
rather than on the older MBR partition tables.
@ -52,21 +48,6 @@ install -Dp -m 0644 fixparts.8 %{buildroot}%{_mandir}/man8/fixparts.8
%{_mandir}/man8/*
%changelog
* Thu Dec 19 2024 lvyy <lyunmail@163.com> - 1.0.9-3
- Updated guid.cc to deal with minor change in libuuid
* Tue Sep 24 2024 lvyy <lyunmail@163.com> - 1.0.9-2
- DESC: fix problem that caused sgdisk to crash when using the latest popt
* Thu Dec 8 2022 tangyuchen <tangyuchen5@huawei.com> - 1.0.9-1
- update to gptfdisk-1.0.9
* Sat Oct 29 2022 wangzhiqiang <wangzhiqiang95@huawei.com> - 1.0.8-3
- remove stray debugging code
* Tue Mar 8 02:11:35 UTC 2022 - Qiang Wei <qiang.wei@suse.com> - 1.0.8-2
- Fix compiler error for option -Werror=format-security
* Wed Nov 17 2021 Wenchao Hao <haowenchao@huawei.com> - 1.0.8-1
- update to gptfdisk-1.0.8

BIN
gptfdisk-1.0.8.tar.gz Normal file

Binary file not shown.

Binary file not shown.