summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xezjail-admin8
1 files changed, 4 insertions, 4 deletions
diff --git a/ezjail-admin b/ezjail-admin
index cf2816e..25b64e3 100755
--- a/ezjail-admin
+++ b/ezjail-admin
@@ -71,12 +71,12 @@ create)
71 # allow foo.com style directory names, however, the jail 71 # allow foo.com style directory names, however, the jail
72 # name will be foo_com in most scripts 72 # name will be foo_com in most scripts
73 newjail_name=`echo $newjail_name | tr /~ __`; 73 newjail_name=`echo $newjail_name | tr /~ __`;
74 newjail_root=${newjail_root:-"$ezjail_jaildir/$newjail_name"} 74 newjail_root=${newjail_root:-"${ezjail_jaildir}/${newjail_name}"}
75 newjail_nname=`echo $newjail_name | tr . _`; 75 newjail_nname=`echo $newjail_name | tr . _`;
76 76
77 # if jail root specified on command line is not absolute, 77 # if jail root specified on command line is not absolute,
78 # make it absolute inside our jail directory 78 # make it absolute inside our jail directory
79 [ ${newjail_root#/} = ${newjail_root} ] || newjail_root=$ezjail_jaildir/$newjail_root 79 [ ${newjail_root#/} = ${newjail_root} ] && newjail_root=$ezjail_jaildir/$newjail_root
80 80
81 # if jail root specified on command line does not lie 81 # if jail root specified on command line does not lie
82 # within our jail directory, we need to create a softlink 82 # within our jail directory, we need to create a softlink
@@ -140,7 +140,7 @@ delete)
140######################## ezjail-admin DELETE ######################## 140######################## ezjail-admin DELETE ########################
141 shift 141 shift
142 args=`getopt w $*` 142 args=`getopt w $*`
143 [ $? = 0 ] || exerr 'Usage: ezjail delete [-w] jailname'; exit 1; 143 [ $? = 0 ] || exerr 'Usage: ezjail delete [-w] jailname';
144 144
145 oldjail_wipe="NO" 145 oldjail_wipe="NO"
146 146
@@ -253,6 +253,6 @@ setup|update)
253 253
254 ;; 254 ;;
255*) 255*)
256 echo "Usage: `basename $0` [create|delete|list|update] {params}"; exit; 256 exerr "Usage: `basename $0` [create|delete|list|update] {params}"
257 ;; 257 ;;
258esac 258esac