aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ali Polatel <alip@exherbo.org> 2010-01-12 12:23:52 +0200
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2010-01-12 16:07:38 +0000
commit2d5fd282b563efc745aec4c2ffdf5a62f469c354 (patch)
treefc7d5f2d865c3913b6bbda8e4c558dd04eed2845
parent6b69bf18f2c0ffe88cdfaf8de0ad5db7735d8e52 (diff)
downloadpaludis-2d5fd282b563efc745aec4c2ffdf5a62f469c354.tar.gz
paludis-2d5fd282b563efc745aec4c2ffdf5a62f469c354.tar.xz
Don't check argument if sydbox command is net/*
-rw-r--r--paludis/repositories/e/ebuild/sydbox.bash14
1 files changed, 11 insertions, 3 deletions
diff --git a/paludis/repositories/e/ebuild/sydbox.bash b/paludis/repositories/e/ebuild/sydbox.bash
index 6e47d50..777cb64 100644
--- a/paludis/repositories/e/ebuild/sydbox.bash
+++ b/paludis/repositories/e/ebuild/sydbox.bash
@@ -1,7 +1,7 @@
#!/usr/bin/env bash
# vim: set sw=4 sts=4 et :
-# Copyright (c) 2009 Ali Polatel <polatel@gmail.com>
+# Copyright (c) 2009, 2010 Ali Polatel <alip@exherbo.org>
#
# Based in part upon ebuild.sh from Portage, which is Copyright 1995-2005
# Gentoo Foundation and distributed under the terms of the GNU General
@@ -29,8 +29,16 @@ sydboxcmd()
{
if sydboxcheck; then
if [[ -n "${2}" ]]; then
- [[ "/" != "${2:0:1}" ]] && die "${FUNCNAME} ${1}: non-absolute path"
- [[ -e /dev/sydbox/${1}/"${2}" ]]
+ case "${1}" in
+ net/*)
+ # net/* commands don't take path arguments
+ [[ -e /dev/sydbox/${1}/"${2}" ]]
+ ;;
+ *)
+ [[ "/" != "${2:0:1}" ]] && die "${FUNCNAME} ${1}: non-absolute path"
+ [[ -e /dev/sydbox/${1}/"${2}" ]]
+ ;;
+ esac
else
[[ -e /dev/sydbox/${1} ]]
fi