summaryrefslogtreecommitdiffstats
path: root/initramfs/initrd-stuff/etc/functions
diff options
context:
space:
mode:
authorMichael Janczyk2008-06-17 16:28:10 +0200
committerMichael Janczyk2008-06-17 16:28:10 +0200
commitf9fd09d032356a40a767ea8b5248e6c2de248464 (patch)
treefef57712c167a3ee5c7965d92a7e72b9f02ff479 /initramfs/initrd-stuff/etc/functions
parentSome bugfixes & FAQ in README added - stupid Bug in slxgroup-parameter (diff)
downloadcore-f9fd09d032356a40a767ea8b5248e6c2de248464.tar.gz
core-f9fd09d032356a40a767ea8b5248e6c2de248464.tar.xz
core-f9fd09d032356a40a767ea8b5248e6c2de248464.zip
changed uri_token function. simpler solution to ticket #232
git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@1883 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'initramfs/initrd-stuff/etc/functions')
-rw-r--r--initramfs/initrd-stuff/etc/functions11
1 files changed, 2 insertions, 9 deletions
diff --git a/initramfs/initrd-stuff/etc/functions b/initramfs/initrd-stuff/etc/functions
index a142f5f2..0d9e20a2 100644
--- a/initramfs/initrd-stuff/etc/functions
+++ b/initramfs/initrd-stuff/etc/functions
@@ -93,16 +93,10 @@ else
rest="$var"
prot=""
fi
-# remove temporary '::' from path, since it conflicts with port specification
-if strinstr "::" "$rest" ; then
- rest=$(echo $rest | sed -e 's,::,§§§§§,g')
-elif strinstr "\:\:" "$rest" ; then
- rest=$(echo $rest | sed -e 's,\:\:,§§§§§,g')
-fi
# get the server IP or name and port - URI authority
# you get the path or other token without leading "/" - add it later if
# needed (fixme: port might be broken)
-if strinstr ":" "$rest" ; then
+if echo "$rest" grep -e "[0-9,a-z]:[0-9]" >/dev/null 2>&1; then
server="${rest%:*}"
rest="${rest#*:}"
path="${rest#*/}"
@@ -123,8 +117,7 @@ fi
case "$2" in
prot) echo "$prot" ;;
server) echo "$server" ;;
- # add '::' again to path
- path) echo "$path" | sed -e 's,§§§§§,\:\:,g' ;;
+ path) echo "$path" ;;
port) echo "$port" ;;
query) echo "$query" ;;
esac