summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthony G. Basile <blueness@gentoo.org>2016-02-29 02:53:08 -0500
committerAnthony G. Basile <blueness@gentoo.org>2016-02-29 02:53:33 -0500
commit270f6af778bcf8f5c6bb68bf9aac10593b20de4d (patch)
tree3d9e2ee704a36b5a463b065a7b7ed3cd1069b765
parentdev-ruby/spring: add 1.6.4 (diff)
downloadgentoo-270f6af7.tar.gz
gentoo-270f6af7.tar.bz2
gentoo-270f6af7.zip
app-misc/fdupes: remove stdin as lvalue, bug #574610
Package-Manager: portage-2.2.26
-rw-r--r--app-misc/fdupes/fdupes-1.51.ebuild5
-rw-r--r--app-misc/fdupes/files/fdupes-1.51-fix-stdin-lvalue.patch20
2 files changed, 23 insertions, 2 deletions
diff --git a/app-misc/fdupes/fdupes-1.51.ebuild b/app-misc/fdupes/fdupes-1.51.ebuild
index 6bff666e0637..8037f87721df 100644
--- a/app-misc/fdupes/fdupes-1.51.ebuild
+++ b/app-misc/fdupes/fdupes-1.51.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2015 Gentoo Foundation
+# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
@@ -26,7 +26,8 @@ src_prepare() {
epatch \
"${FILESDIR}"/${P}-makefile.patch \
"${FILESDIR}"/${PN}-1.50_pre2-compare-file.patch \
- "${FILESDIR}"/${PN}-1.50_pre2-typo.patch
+ "${FILESDIR}"/${PN}-1.50_pre2-typo.patch \
+ "${FILESDIR}"/${P}-fix-stdin-lvalue.patch
append-lfs-flags
}
diff --git a/app-misc/fdupes/files/fdupes-1.51-fix-stdin-lvalue.patch b/app-misc/fdupes/files/fdupes-1.51-fix-stdin-lvalue.patch
new file mode 100644
index 000000000000..65c06e3f1ddf
--- /dev/null
+++ b/app-misc/fdupes/files/fdupes-1.51-fix-stdin-lvalue.patch
@@ -0,0 +1,20 @@
+This is a combination of upstream's fe2d8334 and 03abad. See
+https://bugs.gentoo.org/show_bug.cgi?id=574610.
+
+diff -Naur fdupes-1.51.orig/fdupes.c fdupes-1.51/fdupes.c
+--- fdupes-1.51.orig/fdupes.c 2013-04-20 14:02:18.000000000 -0400
++++ fdupes-1.51/fdupes.c 2016-02-29 02:45:36.360804360 -0500
+@@ -1164,7 +1164,12 @@
+ }
+ else
+ {
+- stdin = freopen("/dev/tty", "r", stdin);
++ if (freopen("/dev/tty", "r", stdin) == 0)
++ {
++ errormsg("could not open terminal for input\n");
++ exit(1);
++ }
++
+ deletefiles(files, 1, stdin);
+ }
+ }