[LEDE-DEV,procd,04/17] Update trace attribute

Message ID 20170912111250.31576-7-sojkam1@fel.cvut.cz
State Accepted
Headers show
Series
  • [LEDE-DEV,procd,01/17] utrace: Fix environment initialization
Related show

Commit Message

Michal Sojka Sept. 12, 2017, 11:12 a.m.
When a service is started for the first time without trace
attribute (e.g. during boot), then it was impossible to restart it in
tracing mode (/etc/init.d/service trace). This is fixed here.

Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
---
 service/instance.c | 1 +
 1 file changed, 1 insertion(+)

Patch

diff --git a/service/instance.c b/service/instance.c
index dc7e3ca..1760a09 100644
--- a/service/instance.c
+++ b/service/instance.c
@@ -941,6 +941,7 @@  instance_config_move(struct service_instance *in, struct service_instance *in_sr
 	in->command = in_src->command;
 	in->pidfile = in_src->pidfile;
 	in->name = in_src->name;
+	in->trace = in_src->trace;
 	in->node.avl.key = in_src->node.avl.key;
 
 	free(in->config);