summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Le Cuirot <chewi@gentoo.org>2020-01-02 20:38:38 +0000
committerJames Le Cuirot <chewi@gentoo.org>2020-01-02 20:38:38 +0000
commitb29a8eee6d90f689232342e632c2418421217649 (patch)
tree8d863b2f41bc636211ab9783c597ed8c66950b76 /app-crypt/rhash
parentgames-util/xboxdrv: add python-3.7 support (diff)
downloadgentoo-b29a8eee6d90f689232342e632c2418421217649.tar.gz
gentoo-b29a8eee6d90f689232342e632c2418421217649.tar.bz2
gentoo-b29a8eee6d90f689232342e632c2418421217649.zip
app-crypt/rhash: Apply upstream patch to fix 1.3.9 -rc segfault
Bug: https://github.com/rhash/RHash/issues/104 Package-Manager: Portage-2.3.84, Repoman-2.3.20 Signed-off-by: James Le Cuirot <chewi@gentoo.org>
Diffstat (limited to 'app-crypt/rhash')
-rw-r--r--app-crypt/rhash/files/rhash-1.3.9-rc-segfault.patch25
-rw-r--r--app-crypt/rhash/rhash-1.3.9-r1.ebuild (renamed from app-crypt/rhash/rhash-1.3.9.ebuild)3
2 files changed, 27 insertions, 1 deletions
diff --git a/app-crypt/rhash/files/rhash-1.3.9-rc-segfault.patch b/app-crypt/rhash/files/rhash-1.3.9-rc-segfault.patch
new file mode 100644
index 000000000000..90a1efecbb15
--- /dev/null
+++ b/app-crypt/rhash/files/rhash-1.3.9-rc-segfault.patch
@@ -0,0 +1,25 @@
+From 198e62063ed817357204284a15f95ffc7230044c Mon Sep 17 00:00:00 2001
+From: Aleksey <rhash.admin@gmail.com>
+Date: Thu, 2 Jan 2020 21:16:51 +0300
+Subject: [PATCH] fix segfault on rhash -rc
+
+---
+ file.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/file.c b/file.c
+index 6f593f9..0d18f45 100644
+--- a/file.c
++++ b/file.c
+@@ -361,8 +361,9 @@ int file_init_by_print_path(file_t* file, file_t* prepend_dir, const char* print
+ const char* path = make_path(prepend_dir->real_path, print_path, 0);
+ file_init(file, path, init_flags & ~FileInitReusePath);
+ }
+- if (!prepend_dir || IS_DOT_STR(prepend_dir->print_path) ||
+- (!prepend_dir->print_path && opt.path_separator != ALIEN_PATH_SEPARATOR)) {
++ if (!prepend_dir || (prepend_dir->print_path ?
++ IS_DOT_STR(prepend_dir->print_path) :
++ opt.path_separator != ALIEN_PATH_SEPARATOR)) {
+ if ((init_flags & FileInitReusePath) != 0) {
+ file->print_path = print_path;
+ file->mode |= FileDontFreePrintPath;
diff --git a/app-crypt/rhash/rhash-1.3.9.ebuild b/app-crypt/rhash/rhash-1.3.9-r1.ebuild
index 2d4c3303cd5a..e203d68814e2 100644
--- a/app-crypt/rhash/rhash-1.3.9.ebuild
+++ b/app-crypt/rhash/rhash-1.3.9-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -32,6 +32,7 @@ S="${WORKDIR}/RHash-${PV}"
PATCHES=(
"${FILESDIR}"/${P}-nls.patch
+ "${FILESDIR}"/${P}-rc-segfault.patch
)
src_prepare() {