1 Purpose: Make sure the .depend.* files have complete dependencies when
2 recursive virtual facilities are used.
6 Index: insserv/insserv.c
7 ===================================================================
8 --- insserv.orig/insserv.c 2009-09-26 22:35:39.000000000 +0200
9 +++ insserv/insserv.c 2009-09-26 22:35:42.000000000 +0200
10 @@ -2109,33 +2109,26 @@
14 - if ((*deep)++ > 10) {
15 - warn("The nested level of the system facilities in the insserv.conf file(s) is to large\n");
19 list_for_each_safe(tmp, safe, ptr) {
20 repl_t * rnxt = getrepl(tmp);
21 if (*rnxt->r[0].name == '$') {
22 - expand_faci(tmp, head, deep);
25 - if (--(*rent->r[0].ref) <= 0)
26 - free(rent->r[0].ref);
27 - rent->r[0] = rnxt->r[0];
28 - ++(*rent->r[0].ref);
30 - repl_t *restrict subst;
31 - if (posix_memalign((void*)&subst, sizeof(void*), alignof(repl_t)) != 0)
32 - error("%s", strerror(errno));
33 - insert(&subst->r_list, head);
34 - subst->r[0] = rnxt->r[0];
35 - ++(*subst->r[0].ref);
37 + warn("The nested level of the system facilities in the insserv.conf file(s) is to large\n");
41 + expand_faci(tmp, head, deep);
43 + } else if (*deep > 0) {
44 + repl_t *restrict subst;
45 + if (posix_memalign((void*)&subst, sizeof(void*), alignof(repl_t)) != 0)
46 + error("%s", strerror(errno));
47 + insert(&subst->r_list, head->prev);
48 + subst->r[0] = rnxt->r[0];
49 + (*subst->r[0].ref) = 1;