diff options
author | Martin Schlemmer <azarah@gentoo.org> | 2006-07-05 09:06:06 +0000 |
---|---|---|
committer | Martin Schlemmer <azarah@gentoo.org> | 2006-07-05 09:06:06 +0000 |
commit | 27186f2435486ed769e4ad1b67890d9261276566 (patch) | |
tree | d6d841ac0e5b244787ee5fc60f362946b047caac /sys-fs | |
parent | add back in arm/s390 (diff) | |
download | gentoo-2-27186f2435486ed769e4ad1b67890d9261276566.tar.gz gentoo-2-27186f2435486ed769e4ad1b67890d9261276566.tar.bz2 gentoo-2-27186f2435486ed769e4ad1b67890d9261276566.zip |
Fix some logic issues and typo's.
(Portage version: 2.1.1_pre2-r2)
Diffstat (limited to 'sys-fs')
-rw-r--r-- | sys-fs/udev/ChangeLog | 5 | ||||
-rwxr-xr-x | sys-fs/udev/files/seq_node.sh | 13 |
2 files changed, 13 insertions, 5 deletions
diff --git a/sys-fs/udev/ChangeLog b/sys-fs/udev/ChangeLog index 8436442a4c2f..b64017275c0c 100644 --- a/sys-fs/udev/ChangeLog +++ b/sys-fs/udev/ChangeLog @@ -1,6 +1,9 @@ # ChangeLog for sys-fs/udev # Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.203 2006/07/04 15:16:25 marienz Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.204 2006/07/05 09:06:06 azarah Exp $ + + 05 Jul 2006; Martin Schlemmer <azarah@gentoo.org> files/seq_node.sh: + Fix some logic issues and typo's. 04 Jul 2006; Marien Zwart <marienz@gentoo.org> Manifest: Fix Manifest (a couple of files mysteriously ended up with an off-by-one diff --git a/sys-fs/udev/files/seq_node.sh b/sys-fs/udev/files/seq_node.sh index 0419bcc4f789..93a6ed9881dc 100755 --- a/sys-fs/udev/files/seq_node.sh +++ b/sys-fs/udev/files/seq_node.sh @@ -2,7 +2,7 @@ # Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # Author: Martin Schlemmer <azarah@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/files/seq_node.sh,v 1.1 2006/06/28 20:04:28 azarah Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/files/seq_node.sh,v 1.2 2006/07/05 09:06:06 azarah Exp $ # Stupid little script to emulate the depriciated '%e' directive of udev. # I am not sure why its supposidly broken, so this might need fixing if it @@ -36,16 +36,21 @@ get_filename() { local symlink=$1 local filename= + if [[ ! -L ${root}/${symlink} ]] ; then + echo "${symlink}" + return 0 + fi + if type -p readlink &>/dev/null ; then - filename=$(readlink "${root}/$1") + filename=$(readlink "${root}/${symlink}") else - filename=`perl -e 'print readlink("${root}/cdrom")' 2>/dev/null` + filename=$(perl -e "print readlink(\"${root}/${symlink}\")" 2>/dev/null) fi echo "${filename}" } -while [[ -f "${root}/${new_node}" || -L "${root}/${new_node}" ]] ; do +while [[ -e "${root}/${new_node}" || -L "${root}/${new_node}" ]] ; do # Check if existing node is the same as the kname we are looking # for a new node, and return that instead if [[ $(get_filename "${new_node}") == "${kname}" ]] ; then |