diff options
Diffstat (limited to 'app-shells')
-rw-r--r-- | app-shells/bash/ChangeLog | 7 | ||||
-rw-r--r-- | app-shells/bash/bash-4.1_p2-r1.ebuild | 3 | ||||
-rw-r--r-- | app-shells/bash/files/bash-4.1-fbsd-eaccess.patch | 29 |
3 files changed, 37 insertions, 2 deletions
diff --git a/app-shells/bash/ChangeLog b/app-shells/bash/ChangeLog index 6dcce28a84a5..f3d64b7c54c1 100644 --- a/app-shells/bash/ChangeLog +++ b/app-shells/bash/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for app-shells/bash # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/ChangeLog,v 1.253 2010/03/28 04:09:09 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/ChangeLog,v 1.254 2010/03/28 10:55:37 the_paya Exp $ + + 28 Mar 2010; Javier Villavicencio <the_paya@gentoo.org> + bash-4.1_p2-r1.ebuild, +files/bash-4.1-fbsd-eaccess.patch: + Fix for bug 303411, reported and patched by Johan Hattne + <johan.hattne@utsouthwestern.edu>. 28 Mar 2010; Mike Frysinger <vapier@gentoo.org> bash-4.0_p37.ebuild: Mark arm/ia64/s390/sh stable #310473. diff --git a/app-shells/bash/bash-4.1_p2-r1.ebuild b/app-shells/bash/bash-4.1_p2-r1.ebuild index fb373b5b01e5..dee1fcefc5f7 100644 --- a/app-shells/bash/bash-4.1_p2-r1.ebuild +++ b/app-shells/bash/bash-4.1_p2-r1.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2010 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/bash-4.1_p2-r1.ebuild,v 1.1 2010/03/23 02:27:42 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/bash-4.1_p2-r1.ebuild,v 1.2 2010/03/28 10:55:37 the_paya Exp $ EAPI="1" @@ -71,6 +71,7 @@ src_unpack() { cd ../.. epatch "${FILESDIR}"/${PN}-4.x-deferred-heredocs.patch + epatch "${FILESDIR}"/${PN}-4.1-fbsd-eaccess.patch # bug 303411 if ! use vanilla ; then sed -i '1i#define NEED_FPURGE_DECL' execute_cmd.c # needs fpurge() decl diff --git a/app-shells/bash/files/bash-4.1-fbsd-eaccess.patch b/app-shells/bash/files/bash-4.1-fbsd-eaccess.patch new file mode 100644 index 000000000000..576a8a47a619 --- /dev/null +++ b/app-shells/bash/files/bash-4.1-fbsd-eaccess.patch @@ -0,0 +1,29 @@ +Bash built-in test fails to correctly report exeuctable status for non- +executable files when run by root on FreeBSD. + +See http://bugs.gentoo.org/303411 + +Patch from Johan Hattne <johan.hattne@utsuthwestern.edu> +--- lib/sh/eaccess.c.orig ++++ lib/sh/eaccess.c +@@ -198,11 +198,19 @@ + char *path; + int mode; + { ++ struct stat s; ++ int ret; ++ + if (path_is_devfd (path)) + return (sh_stataccess (path, mode)); + + #if defined (HAVE_EACCESS) /* FreeBSD */ +- return (eaccess (path, mode)); ++ if (stat (path, &s) != 0) ++ return (-1); ++ ret = eaccess (path, mode); ++ if (mode == X_OK && ret == 0 && !S_ISDIR(s.st_mode) && geteuid() == 0) ++ return ((s.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH)) == 0 ? -1 : 0); ++ return (ret); + #elif defined (EFF_ONLY_OK) /* SVR4(?), SVR4.2 */ + return access (path, mode|EFF_ONLY_OK); + #else |