aboutsummaryrefslogtreecommitdiff
path: root/src/ctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ctl.c')
-rw-r--r--src/ctl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ctl.c b/src/ctl.c
index fd32765..78490cb 100644
--- a/src/ctl.c
+++ b/src/ctl.c
@@ -1855,7 +1855,7 @@ fun_list (struct json_value *result, struct prog *prog)
static int
fun_stop (struct json_value *result, struct prog *prog)
{
- if (prog->v.p.comp->flags & CF_DISABLED)
+ if (prog->v.p.status == status_disabled)
{
json_object_set_string (result, "status", "ER");
json_object_set_string (result, "error_message", "already stopped");
@@ -1873,7 +1873,7 @@ fun_stop (struct json_value *result, struct prog *prog)
static int
fun_start (struct json_value *result, struct prog *prog)
{
- if (prog->v.p.comp->flags & CF_DISABLED)
+ if (prog->v.p.status == status_disabled)
{
prog->v.p.comp->flags &= ~CF_DISABLED;
prog->v.p.status = status_enabled;

Return to:

Send suggestions and report system problems to the System administrator.