Use ${BASH_SOURCE[0]} instead of $_ because the former is more dependable for prevent...
authorZac Medico <zmedico@gentoo.org>
Thu, 8 Jun 2006 22:10:20 +0000 (22:10 -0000)
committerZac Medico <zmedico@gentoo.org>
Thu, 8 Jun 2006 22:10:20 +0000 (22:10 -0000)
svn path=/main/trunk/; revision=3475

bin/sed

diff --git a/bin/sed b/bin/sed
index 6b1a566390599ffe79fc06b75095ad2390f6eca4..d4b1d87b2abe173d7e674c949f6eec152add1cb7 100755 (executable)
--- a/bin/sed
+++ b/bin/sed
@@ -2,7 +2,7 @@
 # Copyright 2006 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
  
-scriptpath=$_
+scriptpath="${BASH_SOURCE[0]}"
 
 if [[ -n ${ESED} ]]; then
        exec ${ESED} "$@"