aboutsummaryrefslogtreecommitdiff
path: root/src/ctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ctl.c')
-rw-r--r--src/ctl.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ctl.c b/src/ctl.c
index f7e46d0..676f93b 100644
--- a/src/ctl.c
+++ b/src/ctl.c
@@ -1715,7 +1715,7 @@ static void
component_stop (struct ctlio *io, struct prog *prog)
{
if (prog->v.p.comp->flags & CF_DISABLED)
- ctlio_reply (io, 409, "already stopped");
+ ctlio_reply (io, 409, "Already stopped");
else
{
progman_stop_component (prog);
@@ -1727,15 +1727,15 @@ component_stop (struct ctlio *io, struct prog *prog)
static void
component_start (struct ctlio *io, struct prog *prog)
{
- if (!(prog->v.p.comp->flags & CF_DISABLED))
- ctlio_reply (io, 409, "already running");
- else
+ if (prog->v.p.comp->flags & CF_DISABLED)
{
prog->v.p.comp->flags &= ~CF_DISABLED;
prog->v.p.status = status_enabled;
kill (getpid (), SIGALRM);
ctlio_reply (io, 200, "Component started");
}
+ else
+ ctlio_reply (io, 409, "Already running");
}
static void

Return to:

Send suggestions and report system problems to the System administrator.