diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2016-02-24 16:01:50 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2016-02-24 16:01:50 +0200 |
commit | 1ec50721c1aa5959009f0c74afc8b7796f4ffd20 (patch) | |
tree | 0dda2c45c87ce03843e876b764d578713a200aa6 /src/acl.c | |
parent | 9912557fa9b4c8596c6e9f69857e9a616b4f4f33 (diff) | |
download | pies-1ec50721c1aa5959009f0c74afc8b7796f4ffd20.tar.gz pies-1ec50721c1aa5959009f0c74afc8b7796f4ffd20.tar.bz2 |
Improve parsing and handling of stop, start, and restart ctl commands.
* src/ctl.c (pcond_active): New type.
(pcond_eval): Handle pcond_active.
(pcond_conv): New op: active.
(pcond_conv_find): Skip array elements with NULL term value.
(object_to_cond): Permit empty argument if no
handler function is defined.
(fun_stop): Work on all prog types.
(fun_start): Work only on components.
(fun_restart): Work only on running components.
* src/piesctl.c (cmdline_parser_state): New member: command.
(pcond_parse_unary): Handle "active" keyword.
(parse_condition): Change signature.
(parse_condition_to_uri): Likewise.
(default_cond): New function,
(com_stop, com_start, com_restart): If no arguments supplied,
assume default condition "type component".
(ctlcom_t): Change signature. All uses changed.
(main): Pass a pointer to cmdline_parser_state to the
command handler.
Diffstat (limited to 'src/acl.c')
0 files changed, 0 insertions, 0 deletions