1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-27 10:25:37 +03:00

service: calculate sysv startup priority only in start runlevels

This commit is contained in:
Lennart Poettering 2010-09-03 04:08:16 +02:00
parent 31091693ec
commit f73d93a4d9

View File

@ -2747,11 +2747,12 @@ static int service_enumerate(Manager *m) {
if (de->d_name[0] == 'S') {
SERVICE(service)->sysv_start_priority =
MAX(a*10 + b, SERVICE(service)->sysv_start_priority);
if (rcnd_table[i].type == RUNLEVEL_UP || rcnd_table[i].type == RUNLEVEL_SYSINIT) {
SERVICE(service)->sysv_start_priority =
MAX(a*10 + b, SERVICE(service)->sysv_start_priority);
if (rcnd_table[i].type == RUNLEVEL_UP || rcnd_table[i].type == RUNLEVEL_SYSINIT)
SERVICE(service)->sysv_enabled = true;
}
if ((r = set_ensure_allocated(&runlevel_services[i], trivial_hash_func, trivial_compare_func)) < 0)
goto finish;