pacman: Removed fix for upstream bug that is now fixed
This commit is contained in:
@@ -1,54 +0,0 @@
|
||||
From 898b9949ab6ad2260ea3d28b70ce63da452966b2 Mon Sep 17 00:00:00 2001
|
||||
From: David Macek <david.macek.0@gmail.com>
|
||||
Date: Tue, 11 Nov 2014 13:17:56 +0100
|
||||
Subject: [PATCH] Fixed crash with XferCommand in .sig file download
|
||||
|
||||
---
|
||||
lib/libalpm/be_sync.c | 24 +++++++++++++++++-------
|
||||
1 file changed, 17 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/lib/libalpm/be_sync.c b/lib/libalpm/be_sync.c
|
||||
index 62fd0f0..c9e189a 100644
|
||||
--- a/lib/libalpm/be_sync.c
|
||||
+++ b/lib/libalpm/be_sync.c
|
||||
@@ -209,7 +209,8 @@ int SYMEXPORT alpm_db_update(int force, alpm_db_t *db)
|
||||
}
|
||||
|
||||
for(i = db->servers; i; i = i->next) {
|
||||
- const char *server = i->data, *final_db_url = NULL;
|
||||
+ char *final_db_url = NULL;
|
||||
+ const char *server = i->data;
|
||||
struct dload_payload payload;
|
||||
size_t len;
|
||||
int sig_ret = 0;
|
||||
@@ -241,12 +242,21 @@ int SYMEXPORT alpm_db_update(int force, alpm_db_t *db)
|
||||
unlink(sigpath);
|
||||
free(sigpath);
|
||||
|
||||
- /* if we downloaded a DB, we want the .sig from the same server */
|
||||
- /* print final_db_url into a buffer (leave space for .sig) */
|
||||
- len = strlen(final_db_url) + 5;
|
||||
- /* TODO fix leak syncpath and umask unset */
|
||||
- MALLOC(payload.fileurl, len, RET_ERR(handle, ALPM_ERR_MEMORY, -1));
|
||||
- snprintf(payload.fileurl, len, "%s.sig", final_db_url);
|
||||
+ if (handle->fetchcb == NULL) {
|
||||
+ /* if we downloaded a DB, we want the .sig from the same server */
|
||||
+ /* print final_db_url into a buffer (leave space for .sig) */
|
||||
+ len = strlen(final_db_url) + 5;
|
||||
+ /* TODO fix leak syncpath and umask unset */
|
||||
+ MALLOC(payload.fileurl, len, RET_ERR(handle, ALPM_ERR_MEMORY, -1));
|
||||
+ snprintf(payload.fileurl, len, "%s.sig", final_db_url);
|
||||
+ } else {
|
||||
+ /* if we downloaded a DB, we want the .sig from the same server */
|
||||
+ /* print server + filename into a buffer (leave space for .sig) */
|
||||
+ len = strlen(server) + strlen(db->treename) + 9;
|
||||
+ /* TODO fix leak syncpath and umask unset */
|
||||
+ MALLOC(payload.fileurl, len, RET_ERR(handle, ALPM_ERR_MEMORY, -1));
|
||||
+ snprintf(payload.fileurl, len, "%s/%s.db.sig", server, db->treename);
|
||||
+ }
|
||||
payload.handle = handle;
|
||||
payload.force = 1;
|
||||
payload.errors_ok = (level & ALPM_SIG_DATABASE_OPTIONAL);
|
||||
--
|
||||
1.8.4.msysgit.0
|
||||
|
||||
@@ -55,8 +55,7 @@ source=("$pkgname"::'git://github.com/Alexpux/MSYS2-pacman.git'
|
||||
"0001-more-debugging-info.patch"
|
||||
"0002-Add-util-msys2.-c-h-and-rebase-db-msys2.-c.patch"
|
||||
"0003-use-busybox-for-msys2-post-installs.patch"
|
||||
"0004-Link-pacman-with-static-libraries.patch"
|
||||
"0005-Fixed-crash-with-XferCommand-in-.sig-file-download.patch")
|
||||
"0004-Link-pacman-with-static-libraries.patch")
|
||||
md5sums=('SKIP'
|
||||
'8fa93febeebaeb62dfa7b63d2846ce52'
|
||||
'8fa93febeebaeb62dfa7b63d2846ce52'
|
||||
@@ -67,8 +66,7 @@ md5sums=('SKIP'
|
||||
'3478ac5ab27b8cdb289d1ac3792b16ec'
|
||||
'feb2bcc62db05f7bc6ac97d43dd0643a'
|
||||
'9ee3ca289031ca9c92db2805b75c1944'
|
||||
'99f8ee6e6df141c9fa98f186ba8fa79c'
|
||||
'03deef84b5c8d3ebf4a02ea8361e1c27')
|
||||
'99f8ee6e6df141c9fa98f186ba8fa79c')
|
||||
|
||||
pkgver() {
|
||||
cd "$srcdir/$pkgname"
|
||||
@@ -82,7 +80,6 @@ prepare() {
|
||||
git am "$srcdir"/0002-Add-util-msys2.-c-h-and-rebase-db-msys2.-c.patch
|
||||
git am "$srcdir"/0003-use-busybox-for-msys2-post-installs.patch
|
||||
git am "$srcdir"/0004-Link-pacman-with-static-libraries.patch
|
||||
git am "$srcdir"/0005-Fixed-crash-with-XferCommand-in-.sig-file-download.patch
|
||||
|
||||
autoreconf -fi
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user