aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Müller <ulm@gentoo.org>2009-04-21 22:06:34 +0000
committerUlrich Müller <ulm@gentoo.org>2009-04-21 22:06:34 +0000
commitb3835f952d951c9eb12fb4f117efe3275e2328a2 (patch)
tree324f3026045694e3664144e7813363714e327a8b
parentClean up. (diff)
downloadeselect-b3835f952d951c9eb12fb4f117efe3275e2328a2.tar.gz
eselect-b3835f952d951c9eb12fb4f117efe3275e2328a2.tar.bz2
eselect-b3835f952d951c9eb12fb4f117efe3275e2328a2.zip
Make functions whitespace safe.
svn path=/trunk/; revision=487
-rw-r--r--ChangeLog3
-rw-r--r--libs/path-manipulation.bash.in10
2 files changed, 7 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index 16b35d3..fcb7f13 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2009-04-21 Ulrich Mueller <ulm@gentoo.org>
+ * libs/path-manipulation.bash.in (basename, dirname)
+ (canonicalise): Quote arguments to make functions whitespace safe.
+
* modules/modules.eselect (do_list, do_has): Fix quoting.
* modules/compiler.eselect.in: Remove dead module.
diff --git a/libs/path-manipulation.bash.in b/libs/path-manipulation.bash.in
index 65baefd..2e6df0d 100644
--- a/libs/path-manipulation.bash.in
+++ b/libs/path-manipulation.bash.in
@@ -1,6 +1,6 @@
#!/bin/bash
-# Copyright (c) 2005-2006 Gentoo Foundation.
+# Copyright (c) 2005-2009 Gentoo Foundation.
# $Id$
# This file is part of the 'eselect' tools framework.
#
@@ -18,18 +18,16 @@
# basename wrapper
basename() {
- echo ${1##*/}
+ echo "${1##*/}"
}
# dirname wrapper
dirname() {
- echo ${1%/*}
+ echo "${1%/*}"
}
canonicalise() {
- @CANONICALISE@ $*
+ @CANONICALISE@ "$@"
}
# vim: set sw=4 et sts=4 tw=80 :
-
-