diff options
author | Russ Allbery <rra@stanford.edu> | 2007-09-01 00:47:58 +0000 |
---|---|---|
committer | Russ Allbery <rra@stanford.edu> | 2007-09-01 00:47:58 +0000 |
commit | 60b909b6308137353546f3625846a160f327ba27 (patch) | |
tree | 725eca8d95c35b1a891373a709f30dba8e2cfbbb /server | |
parent | d365eeaa68672f435db87e191b9cd86ac44e3e57 (diff) |
Add acl destroy as a command, add newlines after the owner, expires, and
getacl returns, and handle undef returns from owner, expires, and getacl
that aren't errors.
Diffstat (limited to 'server')
-rwxr-xr-x | server/wallet-backend | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/server/wallet-backend b/server/wallet-backend index 6fed995..4757d45 100755 --- a/server/wallet-backend +++ b/server/wallet-backend @@ -71,6 +71,9 @@ if ($command eq 'acl') { } elsif ($action eq 'create') { check_args (1, [], @args); $server->acl_create (@args) or die $server->error; + } elsif ($action eq 'destroy') { + check_args (1, [], @args); + $server->acl_destroy (@args) or die $server->error; } elsif ($action eq 'remove') { check_args (3, [], @args); $server->acl_remove (@args) or die $server->error; @@ -92,7 +95,9 @@ if ($command eq 'acl') { check_args (2, [], @args); my $output = $server->expires (@args); if (defined $output) { - print $output; + print $output, "\n"; + } elsif (not $server->error) { + print "No expiration set\n"; } else { die $server->error; } @@ -109,7 +114,9 @@ if ($command eq 'acl') { check_args (3, [], @args); my $output = $server->acl (@args); if (defined $output) { - print $output; + print $output, "\n"; + } elsif (not $server->error) { + print "No ACL set\n"; } else { die $server->error; } @@ -121,7 +128,9 @@ if ($command eq 'acl') { check_args (2, [], @args); my $output = $server->owner (@args); if (defined $output) { - print $output; + print $output, "\n"; + } elsif (not $server->error) { + print "No owner set\n"; } else { die $server->error; } |