Merge pull request #3152 from poettering/aliasfix

Refuse aliases to non-aliasable units in more places

Fixes #2730.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2016-04-30 18:00:46 -04:00
8 changed files with 51 additions and 51 deletions
+4 -6
View File
@@ -1773,20 +1773,18 @@ int set_consume(Set *s, void *value) {
int set_put_strdup(Set *s, const char *p) {
char *c;
int r;
assert(s);
assert(p);
if (set_contains(s, (char*) p))
return 0;
c = strdup(p);
if (!c)
return -ENOMEM;
r = set_consume(s, c);
if (r == -EEXIST)
return 0;
return r;
return set_consume(s, c);
}
int set_put_strdupv(Set *s, char **l) {