diff options
author | Roy Marples <roy@marples.name> | 2008-06-04 19:07:09 +0000 |
---|---|---|
committer | Roy Marples <roy@marples.name> | 2008-06-04 19:07:09 +0000 |
commit | 3525e602d6bd32fe1ee11d03ce644fe6d250a290 (patch) | |
tree | 4565e5ed52c819d81d16c5c4a39284cf83b7d2b5 /src/librc/librc-depend.c | |
parent | 79ebd89d19c2bece426e16cfddf79d642854aeb5 (diff) |
Use addu instead of another loop.
Diffstat (limited to 'src/librc/librc-depend.c')
-rw-r--r-- | src/librc/librc-depend.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/librc/librc-depend.c b/src/librc/librc-depend.c index 26fc5c41..f827efe8 100644 --- a/src/librc/librc-depend.c +++ b/src/librc/librc-depend.c @@ -774,7 +774,7 @@ rc_deptree_update(void) continue; if (strcmp(type, "config") == 0) { - rc_stringlist_add(config, depend); + rc_stringlist_addu(config, depend); continue; } @@ -891,11 +891,7 @@ rc_deptree_update(void) dt->services = rc_stringlist_new(); STAILQ_INSERT_TAIL(&di->depends, dt, entries); } - TAILQ_FOREACH(s2, dt->services, entries) - if (strcmp(s2->value, depinfo->service) == 0) - break; - if (!s2) - rc_stringlist_add(dt->services, depinfo->service); + rc_stringlist_addu(dt->services, depinfo->service); } } |