Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 467368 | Differences between
and this patch

Collapse All | Expand All

(-)openrc-10a4385.orig/src/librc/librc.c (-7 / +33 lines)
Lines 443-448 Link Here
443
}
443
}
444
librc_hidden_def(rc_runlevel_stacks)
444
librc_hidden_def(rc_runlevel_stacks)
445
445
446
/* Returns a list of all the chained runlevels used by the
447
 * specified runlevel in dependency order, including the
448
 * specified runlevel. */
449
void
450
rc_get_runlevel_chain(const char *runlevel, RC_STRINGLIST *level_list)
451
{
452
	// If we haven't been passed a runlevel or a level list, or
453
	// if the passed runlevel doesn't exist then we're done already!
454
	if (!runlevel || !level_list || !rc_runlevel_exists(runlevel))
455
		return;
456
457
	// We want to add this runlevel to the list but if
458
	// it is already in the list it needs to go at the
459
	// end again.
460
	if (rc_stringlist_find(level_list, runlevel))
461
		rc_stringlist_delete(level_list, runlevel);
462
	rc_stringlist_add(level_list, runlevel);
463
464
	// We can now do exactly the above procedure for our chained
465
	// runlevels.
466
	char path[PATH_MAX];
467
	RC_STRINGLIST *dirs;
468
	RC_STRING *d, *dn;
469
	snprintf(path, sizeof(path), "%s/%s", RC_RUNLEVELDIR, runlevel);
470
	dirs = ls_dir(path, LS_DIR);
471
	TAILQ_FOREACH_SAFE(d, dirs, entries, dn)
472
		rc_get_runlevel_chain(d->value, level_list);
473
}
474
librc_hidden_def(rc_get_runlevel_chain)
475
446
/* Resolve a service name to its full path */
476
/* Resolve a service name to its full path */
447
char *
477
char *
448
rc_service_resolve(const char *service)
478
rc_service_resolve(const char *service)
Lines 902-919 Link Here
902
	list = rc_services_in_runlevel(runlevel);
932
	list = rc_services_in_runlevel(runlevel);
903
	stacks = rc_runlevel_stacks(runlevel);
933
	stacks = rc_runlevel_stacks(runlevel);
904
	TAILQ_FOREACH(stack, stacks, entries) {
934
	TAILQ_FOREACH(stack, stacks, entries) {
905
		sl = rc_services_in_runlevel(stack->value);
935
		sl = rc_services_in_runlevel_stacked(stack->value);
906
		if (list != NULL) {
936
		TAILQ_CONCAT(list, sl, entries);
907
			TAILQ_CONCAT(list, sl, entries);
937
		free(sl);
908
			free(sl);
909
		} else
910
			list = sl;
911
	}
938
	}
912
	return list;
939
	return list;
913
}
940
}
914
librc_hidden_def(rc_services_in_runlevel_stacked)
941
librc_hidden_def(rc_services_in_runlevel_stacked)
915
942
916
917
RC_STRINGLIST *
943
RC_STRINGLIST *
918
rc_services_in_state(RC_SERVICE state)
944
rc_services_in_state(RC_SERVICE state)
919
{
945
{
(-)openrc-10a4385.orig/src/librc/librc.h (+1 lines)
Lines 95-100 Link Here
95
librc_hidden_proto(rc_runlevel_set)
95
librc_hidden_proto(rc_runlevel_set)
96
librc_hidden_proto(rc_runlevel_stack)
96
librc_hidden_proto(rc_runlevel_stack)
97
librc_hidden_proto(rc_runlevel_stacks)
97
librc_hidden_proto(rc_runlevel_stacks)
98
librc_hidden_proto(rc_get_runlevel_chain)
98
librc_hidden_proto(rc_runlevel_starting)
99
librc_hidden_proto(rc_runlevel_starting)
99
librc_hidden_proto(rc_runlevel_stopping)
100
librc_hidden_proto(rc_runlevel_stopping)
100
librc_hidden_proto(rc_runlevel_unstack)
101
librc_hidden_proto(rc_runlevel_unstack)
(-)openrc-10a4385.orig/src/librc/rc.h.in (+4 lines)
Lines 111-116 Link Here
111
 * @return a NULL terminated list of runlevels */
111
 * @return a NULL terminated list of runlevels */
112
RC_STRINGLIST *rc_runlevel_stacks(const char *);
112
RC_STRINGLIST *rc_runlevel_stacks(const char *);
113
113
114
/*! Return a NULL terminated list of runlevels in the runlevel chain
115
 * @return a NULL terminated list of runlevels */
116
void rc_get_runlevel_chain(const char *, RC_STRINGLIST *);
117
114
/*! Return a NULL terminated list of runlevels
118
/*! Return a NULL terminated list of runlevels
115
 * @return a NULL terminated list of runlevels */
119
 * @return a NULL terminated list of runlevels */
116
RC_STRINGLIST *rc_runlevel_list(void);
120
RC_STRINGLIST *rc_runlevel_list(void);
(-)openrc-10a4385.orig/src/librc/rc.map (+1 lines)
Lines 25-30 Link Here
25
	rc_runlevel_set;
25
	rc_runlevel_set;
26
	rc_runlevel_stack;
26
	rc_runlevel_stack;
27
	rc_runlevel_stacks;
27
	rc_runlevel_stacks;
28
	rc_get_runlevel_chain;
28
	rc_runlevel_starting;
29
	rc_runlevel_starting;
29
	rc_runlevel_stopping;
30
	rc_runlevel_stopping;
30
	rc_runlevel_unstack;
31
	rc_runlevel_unstack;
(-)openrc-10a4385.orig/src/rc/rc.c (-52 / +69 lines)
Lines 79-94 Link Here
79
79
80
const char *applet = NULL;
80
const char *applet = NULL;
81
static char *runlevel;
81
static char *runlevel;
82
static RC_STRINGLIST *hotplugged_services;
83
static RC_STRINGLIST *stop_services;
84
static RC_STRINGLIST *start_services;
85
static RC_STRINGLIST *types_n;
86
static RC_STRINGLIST *types_nua;
87
static RC_DEPTREE *deptree;
88
static RC_HOOK hook_out;
82
static RC_HOOK hook_out;
89
90
struct termios *termios_orig = NULL;
83
struct termios *termios_orig = NULL;
91
92
RC_PIDLIST service_pids;
84
RC_PIDLIST service_pids;
93
85
94
static void
86
static void
Lines 113-120 Link Here
113
			snprintf(path, l, RC_SVCDIR "/failed/%s", d->d_name);
105
			snprintf(path, l, RC_SVCDIR "/failed/%s", d->d_name);
114
			if (path) {
106
			if (path) {
115
				if (unlink(path))
107
				if (unlink(path))
116
					eerror("%s: unlink `%s': %s",
108
					eerror("%s: unlink `%s': %s", applet, path, strerror(errno));
117
					    applet, path, strerror(errno));
118
				free(path);
109
				free(path);
119
			}
110
			}
120
		}
111
		}
Lines 524-530 Link Here
524
}
515
}
525
516
526
static void
517
static void
527
do_stop_services(const char *newlevel, bool parallel, bool going_down)
518
do_stop_services(const RC_STRINGLIST *types_n, const RC_STRINGLIST *start_services,
519
				 const RC_STRINGLIST *stop_services, const RC_DEPTREE *deptree,
520
				 const char *newlevel, bool parallel, bool going_down)
528
{
521
{
529
	pid_t pid;
522
	pid_t pid;
530
	RC_STRING *service, *svc1, *svc2;
523
	RC_STRING *service, *svc1, *svc2;
Lines 581-588 Link Here
581
				 * be stopped if we have a runlevel
574
				 * be stopped if we have a runlevel
582
				 * configuration file for either the current
575
				 * configuration file for either the current
583
				 * or next so we use the correct one. */
576
				 * or next so we use the correct one. */
584
				if (!runlevel_config(service->value,runlevel) &&
577
				if (!runlevel_config(service->value, runlevel) &&
585
				    !runlevel_config(service->value,newlevel))
578
				    !runlevel_config(service->value, newlevel))
586
					continue;
579
					continue;
587
			}
580
			}
588
			else
581
			else
Lines 627-633 Link Here
627
}
620
}
628
621
629
static void
622
static void
630
do_start_services(bool parallel)
623
do_start_services(const RC_STRINGLIST *start_services, bool parallel)
631
{
624
{
632
	RC_STRING *service;
625
	RC_STRING *service;
633
	pid_t pid;
626
	pid_t pid;
Lines 754-759 Link Here
754
{
747
{
755
	const char *bootlevel = NULL;
748
	const char *bootlevel = NULL;
756
	char *newlevel = NULL;
749
	char *newlevel = NULL;
750
	static RC_STRINGLIST *hotplugged_services;
751
	static RC_STRINGLIST *stop_services;
752
	static RC_STRINGLIST *start_services;
753
	static RC_STRINGLIST *types_n;
754
	static RC_STRINGLIST *types_nua;
755
	static RC_DEPTREE *deptree;
757
	RC_STRINGLIST *deporder = NULL;
756
	RC_STRINGLIST *deporder = NULL;
758
	RC_STRINGLIST *tmplist;
757
	RC_STRINGLIST *tmplist;
759
	RC_STRING *service;
758
	RC_STRING *service;
Lines 893-898 Link Here
893
	/* Now we start handling our children */
892
	/* Now we start handling our children */
894
	signal_setup(SIGCHLD, handle_signal);
893
	signal_setup(SIGCHLD, handle_signal);
895
894
895
	/* Are we heading for a shutdown or a transition to single user mode? */
896
	if (newlevel &&
896
	if (newlevel &&
897
	    (strcmp(newlevel, RC_LEVEL_SHUTDOWN) == 0 ||
897
	    (strcmp(newlevel, RC_LEVEL_SHUTDOWN) == 0 ||
898
		strcmp(newlevel, RC_LEVEL_SINGLE) == 0))
898
		strcmp(newlevel, RC_LEVEL_SINGLE) == 0))
Lines 972-979 Link Here
972
		    applet, RC_STOPPING, strerror(errno));
972
		    applet, RC_STOPPING, strerror(errno));
973
	}
973
	}
974
974
975
	/* Build a list of all services to stop and then work out the
975
	/* Create a list of all services which we could stop (assuming
976
	 * correct order for stopping them */
976
	 * they won't be active in the new or current runlevel) including
977
	 * all those services which have been started, are inactive or
978
	 * are currently starting.  Clearly, some of these will be listed
979
	 * in the new or current runlevel so we won't actually be stopping
980
	 * them all.
981
	 */
977
	stop_services = rc_services_in_state(RC_SERVICE_STARTED);
982
	stop_services = rc_services_in_state(RC_SERVICE_STARTED);
978
	tmplist = rc_services_in_state(RC_SERVICE_INACTIVE);
983
	tmplist = rc_services_in_state(RC_SERVICE_INACTIVE);
979
	TAILQ_CONCAT(stop_services, tmplist, entries);
984
	TAILQ_CONCAT(stop_services, tmplist, entries);
Lines 990-1026 Link Here
990
	rc_stringlist_add(types_nua, "iafter");
995
	rc_stringlist_add(types_nua, "iafter");
991
996
992
	if (stop_services) {
997
	if (stop_services) {
993
		tmplist = rc_deptree_depends(deptree, types_nua, stop_services,
998
		tmplist = rc_deptree_depends(deptree, types_nua, stop_services, runlevel, depoptions | RC_DEP_STOP);
994
		    runlevel, depoptions | RC_DEP_STOP);
995
		rc_stringlist_free(stop_services);
999
		rc_stringlist_free(stop_services);
996
		stop_services = tmplist;
1000
		stop_services = tmplist;
997
	}
1001
	}
998
1002
999
	/* Load our list of start services */
1003
	/* Create a list of all services which should be started for the new or
1004
	 * current runlevel including those in boot, sysinit and hotplugged
1005
	 * runlevels.  Clearly, some of these will already be started so we
1006
	 * won't actually be starting them all.
1007
	 */
1000
	hotplugged_services = rc_services_in_state(RC_SERVICE_HOTPLUGGED);
1008
	hotplugged_services = rc_services_in_state(RC_SERVICE_HOTPLUGGED);
1001
	start_services = rc_services_in_runlevel_stacked(newlevel ?
1009
	start_services = rc_services_in_runlevel_stacked(newlevel ? newlevel : runlevel);
1002
	    newlevel : runlevel);
1003
	if (strcmp(newlevel ? newlevel : runlevel, RC_LEVEL_SHUTDOWN) != 0 &&
1010
	if (strcmp(newlevel ? newlevel : runlevel, RC_LEVEL_SHUTDOWN) != 0 &&
1004
	    strcmp(newlevel ? newlevel : runlevel, RC_LEVEL_SYSINIT) != 0)
1011
	    strcmp(newlevel ? newlevel : runlevel, RC_LEVEL_SYSINIT) != 0)
1005
	{
1012
	{
1006
		tmplist = rc_services_in_runlevel(RC_LEVEL_SYSINIT);
1013
		tmplist = rc_services_in_runlevel(RC_LEVEL_SYSINIT);
1007
		TAILQ_CONCAT(start_services, tmplist, entries);
1014
		TAILQ_CONCAT(start_services, tmplist, entries);
1008
		free(tmplist);
1015
		free(tmplist);
1009
		if (strcmp(newlevel ? newlevel : runlevel,
1016
		// If we are NOT headed for the single-user runlevel...
1010
			RC_LEVEL_SINGLE) != 0)
1017
		if (strcmp(newlevel ? newlevel : runlevel, RC_LEVEL_SINGLE) != 0)
1011
		{
1018
		{
1012
			if (strcmp(newlevel ? newlevel : runlevel,
1019
			// If we are NOT headed for the boot runlevel...
1013
				bootlevel) != 0)
1020
			if (strcmp(newlevel ? newlevel : runlevel, bootlevel) != 0)
1014
			{
1021
			{
1015
				tmplist = rc_services_in_runlevel(bootlevel);
1022
				tmplist = rc_services_in_runlevel(bootlevel);
1016
				TAILQ_CONCAT(start_services, tmplist, entries);
1023
				TAILQ_CONCAT(start_services, tmplist, entries);
1017
				free(tmplist);
1024
				free(tmplist);
1018
			}
1025
			}
1019
			if (hotplugged_services) {
1026
			if (hotplugged_services) {
1020
				TAILQ_FOREACH(service, hotplugged_services,
1027
				TAILQ_FOREACH(service, hotplugged_services, entries)
1021
				    entries)
1028
				    rc_stringlist_addu(start_services, service->value);
1022
				    rc_stringlist_addu(start_services,
1023
					service->value);
1024
			}
1029
			}
1025
		}
1030
		}
1026
	}
1031
	}
Lines 1029-1042 Link Here
1029
1034
1030
	/* Now stop the services that shouldn't be running */
1035
	/* Now stop the services that shouldn't be running */
1031
	if (stop_services && !nostop)
1036
	if (stop_services && !nostop)
1032
		do_stop_services(newlevel, parallel, going_down);
1037
		do_stop_services(types_n, start_services, stop_services, deptree, newlevel, parallel, going_down);
1033
1038
1034
	/* Wait for our services to finish */
1039
	/* Wait for our services to finish */
1035
	wait_for_services();
1040
	wait_for_services();
1036
1041
1037
	/* Notify the plugins we have finished */
1042
	/* Notify the plugins we have finished */
1038
	rc_plugin_run(RC_HOOK_RUNLEVEL_STOP_OUT,
1043
	rc_plugin_run(RC_HOOK_RUNLEVEL_STOP_OUT, going_down ? newlevel : runlevel);
1039
	    going_down ? newlevel : runlevel);
1040
	hook_out = 0;
1044
	hook_out = 0;
1041
1045
1042
	rmdir(RC_STOPPING);
1046
	rmdir(RC_STOPPING);
Lines 1065-1082 Link Here
1065
		TAILQ_FOREACH(service, hotplugged_services, entries)
1069
		TAILQ_FOREACH(service, hotplugged_services, entries)
1066
		    rc_service_mark(service->value, RC_SERVICE_HOTPLUGGED);
1070
		    rc_service_mark(service->value, RC_SERVICE_HOTPLUGGED);
1067
1071
1068
	/* Order the services to start */
1069
	if (start_services) {
1070
		rc_stringlist_sort(&start_services);
1071
		deporder = rc_deptree_depends(deptree, types_nua,
1072
		    start_services, runlevel,
1073
		    depoptions | RC_DEP_START);
1074
		rc_stringlist_free(start_services);
1075
		start_services = deporder;
1076
	}
1077
1078
#ifdef __linux__
1072
#ifdef __linux__
1079
	/* mark any services skipped as started */
1073
	/* If the "noinit" parameter was passed on the kernel command line then
1074
	 * mark the specified services as started so they will not be started
1075
	 * by us. */
1080
	proc = p = rc_proc_getent("noinit");
1076
	proc = p = rc_proc_getent("noinit");
1081
	if (proc) {
1077
	if (proc) {
1082
		while ((token = strsep(&p, ",")))
1078
		while ((token = strsep(&p, ",")))
Lines 1085-1103 Link Here
1085
	}
1081
	}
1086
#endif
1082
#endif
1087
1083
1088
	if (start_services) {
1084
	// If we have a list of services to start then...
1089
		do_start_services(parallel);
1085
	if (start_services)
1090
		/* FIXME: If we skip the boot runlevel and go straight
1086
	{
1091
		 * to default from sysinit, we should now re-evaluate our
1087
		// Get a list of the chained runlevels which compose the target runlevel
1092
		 * start services + hotplugged services and call
1088
		RC_STRINGLIST *runlevel_chain = rc_stringlist_new();
1093
		 * do_start_services a second time. */
1089
		rc_get_runlevel_chain(runlevel, runlevel_chain);
1090
1091
		// Loop through them in reverse order.
1092
		RC_STRING *rlevel;
1093
		TAILQ_FOREACH_REVERSE(rlevel, runlevel_chain, rc_stringlist, entries)
1094
		{
1095
			// Get a list of all the services in that runlevel
1096
			RC_STRINGLIST *run_services = rc_services_in_runlevel(rlevel->value);
1097
1098
			// Start those services.
1099
			rc_stringlist_sort(&run_services);
1100
			deporder = rc_deptree_depends(deptree, types_nua, run_services, rlevel->value, depoptions | RC_DEP_START);
1101
			rc_stringlist_free(run_services);
1102
			run_services = deporder;
1103
			do_start_services(run_services, parallel);
1094
1104
1095
		/* Wait for our services to finish */
1105
			/* Wait for our services to finish */
1096
		wait_for_services();
1106
			wait_for_services();
1107
1108
			// Free the list of services, we're done with it.
1109
			rc_stringlist_free(run_services);
1110
		}
1111
		rc_stringlist_free(runlevel_chain);
1097
	}
1112
	}
1098
1113
1099
#ifdef __linux__
1114
#ifdef __linux__
1100
	/* mark any services skipped as stopped */
1115
	/* If the "noinit" parameter was passed on the kernel command line then
1116
	 * mark the specified services as stopped so that our records reflect
1117
	 * reality.	 */
1101
	proc = p = rc_proc_getent("noinit");
1118
	proc = p = rc_proc_getent("noinit");
1102
	if (proc) {
1119
	if (proc) {
1103
		while ((token = strsep(&p, ",")))
1120
		while ((token = strsep(&p, ",")))
(-)openrc-10a4385.orig/src/rc/rc-status.c (-30 / +38 lines)
Lines 171-176 Link Here
171
	rc_stringlist_free(l);
171
	rc_stringlist_free(l);
172
}
172
}
173
173
174
static void
175
print_stacked_services(const char *runlevel)
176
{
177
	RC_STRINGLIST *stackedlevels, *servicelist;
178
	RC_STRING *stackedlevel;
179
180
	stackedlevels = rc_runlevel_stacks(runlevel);
181
	TAILQ_FOREACH(stackedlevel, stackedlevels, entries) {
182
		if (rc_stringlist_find(levels, stackedlevel->value) != NULL)
183
			continue;
184
		print_level("Stacked", stackedlevel->value);
185
		servicelist = rc_services_in_runlevel(stackedlevel->value);
186
		print_services(stackedlevel->value, servicelist);
187
		rc_stringlist_free(servicelist);
188
		print_stacked_services(stackedlevel->value);
189
	}
190
	rc_stringlist_free(stackedlevels);
191
	stackedlevels = NULL;
192
}
193
194
174
#include "_usage.h"
195
#include "_usage.h"
175
#define usagestring ""						\
196
#define usagestring ""						\
176
	"Usage: rc-status [options] <runlevel>...\n"		\
197
	"Usage: rc-status [options] <runlevel>...\n"		\
Lines 199-205 Link Here
199
int
220
int
200
rc_status(int argc, char **argv)
221
rc_status(int argc, char **argv)
201
{
222
{
202
	RC_STRING *s, *l, *t;
223
	RC_STRING *s, *l, *t, *level;
203
	char *p, *runlevel = NULL;
224
	char *p, *runlevel = NULL;
204
	int opt, aflag = 0, retval = 0;
225
	int opt, aflag = 0, retval = 0;
205
226
Lines 280-297 Link Here
280
		print_level(NULL, l->value);
301
		print_level(NULL, l->value);
281
		services = rc_services_in_runlevel(l->value);
302
		services = rc_services_in_runlevel(l->value);
282
		print_services(l->value, services);
303
		print_services(l->value, services);
283
		nservices = rc_runlevel_stacks(l->value);
304
		print_stacked_services(l->value);
284
		TAILQ_FOREACH(s, nservices, entries) {
285
			if (rc_stringlist_find(levels, s->value) != NULL)
286
				continue;
287
			print_level("Stacked", s->value);
288
			sservices = rc_services_in_runlevel(s->value);
289
			print_services(s->value, sservices);
290
			rc_stringlist_free(sservices);
291
		}
292
		sservices = NULL;
293
		rc_stringlist_free(nservices);
294
		nservices = NULL;
295
		rc_stringlist_free(services);
305
		rc_stringlist_free(services);
296
		services = NULL;
306
		services = NULL;
297
	}
307
	}
Lines 317-332 Link Here
317
		services = rc_services_in_runlevel(NULL);
327
		services = rc_services_in_runlevel(NULL);
318
		sservices = rc_stringlist_new();
328
		sservices = rc_stringlist_new();
319
		TAILQ_FOREACH(l, levels, entries) {
329
		TAILQ_FOREACH(l, levels, entries) {
320
			nservices = rc_services_in_runlevel(l->value);
330
			nservices = rc_services_in_runlevel_stacked(l->value);
321
			TAILQ_CONCAT(sservices, nservices, entries);
331
			TAILQ_CONCAT(sservices, nservices, entries);
322
			free(nservices);
332
			free(nservices);
323
		}
333
		}
324
		TAILQ_FOREACH_SAFE(s, services, entries, t) {
334
		TAILQ_FOREACH_SAFE(s, services, entries, t) {
325
			if (rc_stringlist_find(sservices, s->value) ||
335
			if ((rc_stringlist_find(sservices, s->value) ||
326
			    rc_service_state(s->value) &
336
			    (rc_service_state(s->value) & (RC_SERVICE_STOPPED | RC_SERVICE_HOTPLUGGED)))) {
327
			    (RC_SERVICE_STOPPED | RC_SERVICE_HOTPLUGGED))
337
				TAILQ_REMOVE(services, s, entries);
328
		{
329
			TAILQ_REMOVE(services, s, entries);
330
				free(s->value);
338
				free(s->value);
331
				free(s);
339
				free(s);
332
			}
340
			}
Lines 337-356 Link Here
337
		alist = rc_stringlist_new();
345
		alist = rc_stringlist_new();
338
		l = rc_stringlist_add(alist, "");
346
		l = rc_stringlist_add(alist, "");
339
		p = l->value;
347
		p = l->value;
340
		if (!runlevel)
348
		TAILQ_FOREACH(level, levels, entries) {
341
			runlevel = rc_runlevel_get();
349
			TAILQ_FOREACH_SAFE(s, services, entries, t) {
342
		TAILQ_FOREACH_SAFE(s, services, entries, t) {
350
				l->value = s->value;
343
			l->value = s->value;
351
				setenv("RC_SVCNAME", l->value, 1);
344
			unsetenv("RC_SVCNAME");
352
				tmp = rc_deptree_depends(deptree, needsme, alist, level->value, RC_DEP_TRACE);
345
			setenv("RC_SVCNAME", l->value, 1);
353
				if (TAILQ_FIRST(tmp)) {
346
			tmp = rc_deptree_depends(deptree, needsme, alist, runlevel, RC_DEP_TRACE);
354
					TAILQ_REMOVE(services, s, entries);
347
			if (TAILQ_FIRST(tmp)) {
355
					TAILQ_INSERT_TAIL(nservices, s, entries);
348
				TAILQ_REMOVE(services, s, entries);
356
				}
349
				TAILQ_INSERT_TAIL(nservices, s, entries);
357
				rc_stringlist_free(tmp);
350
			}
358
			}
351
			rc_stringlist_free(tmp);
352
		}
359
		}
353
		l->value = p;
360
		l->value = p;
361
		unsetenv("RC_SVCNAME");
354
		print_level("Dynamic", "needed");
362
		print_level("Dynamic", "needed");
355
		print_services(NULL, nservices);
363
		print_services(NULL, nservices);
356
		print_level("Dynamic", "manual");
364
		print_level("Dynamic", "manual");

Return to bug 467368