2
0
mirror of https://gitlab.com/apparmor/apparmor synced 2025-09-05 16:55:32 +00:00

Fix many compile-time warnings.

Start replacing RPM with lsb-release.
Drop old references to CVE.
Remove unused code.
This commit is contained in:
Kees Cook
2010-07-26 09:22:45 -07:00
parent a92f9e67b3
commit 624aee531a
8 changed files with 21 additions and 60 deletions

View File

@@ -425,10 +425,13 @@ static int __expand_variable(struct symtab *symbol)
for (ref_item = ref->expanded; ref_item; ref_item = ref_item->next) {
char *expanded_string;
asprintf(&expanded_string, "%s%s%s",
if (!asprintf(&expanded_string, "%s%s%s",
split->prefix ? split->prefix : "",
ref_item->val,
split->suffix ? split->suffix : "");
split->suffix ? split->suffix : "")) {
PERROR("Out of memory\n");
exit(1);
}
add_to_set(&work_list, expanded_string);
free(expanded_string);
}