summaryrefslogtreecommitdiffstats
path: root/setacls.py
diff options
context:
space:
mode:
authorJon Stanley <jonstanley@gmail.com>2009-12-09 23:43:41 -0500
committerJon Stanley <jonstanley@gmail.com>2009-12-09 23:43:41 -0500
commit9e15ed21337ca8702f8466ff73c83223e36985ec (patch)
tree32425f13fa47ebaa05105ad1fce8b1d6fc11df0b /setacls.py
parent56d5fba149e95ccfb07f185a3778d22260454a50 (diff)
downloadcvssetfacl-9e15ed21337ca8702f8466ff73c83223e36985ec.tar.gz
cvssetfacl-9e15ed21337ca8702f8466ff73c83223e36985ec.tar.xz
cvssetfacl-9e15ed21337ca8702f8466ff73c83223e36985ec.zip
Fix some errors in option parsing error handling
- Change to actually exit when an invalid condition exists -- Both the -a and pkgs and -a and no pkgs were fixed
Diffstat (limited to 'setacls.py')
-rwxr-xr-xsetacls.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/setacls.py b/setacls.py
index de1b576..f42de0a 100755
--- a/setacls.py
+++ b/setacls.py
@@ -180,10 +180,12 @@ def main():
pkgs[pkg] = parsed
if not options.all and not args:
- sys.stderr.write('either the -a option or some packages must be given')
+ sys.stderr.write('either the -a option or some packages must be given\n')
+ sys.exit(1)
if options.all and args:
- sys.stderr.write('You cannot specify both -a and a list of packages')
+ sys.stderr.write('You cannot specify both -a and a list of packages\n')
+ sys.exit(1)
if options.all:
acl_list = get_all()