From 9c84d166d34399061330ff651f11e12622bc0700 Mon Sep 17 00:00:00 2001 From: rm88369 Date: Wed, 27 Sep 2006 05:14:58 -0700 Subject: 6408879 /usr/bin/bart create not including all files in manifest for multiple subtrees in a block 6408957 global rules for /usr/bin/bart not working properly 6408975 adding excluding pattern to rules file for /usr/bin/bart has unexpected side-effects --- usr/src/cmd/bart/create.c | 26 +------------------------- 1 file changed, 1 insertion(+), 25 deletions(-) (limited to 'usr/src/cmd/bart/create.c') diff --git a/usr/src/cmd/bart/create.c b/usr/src/cmd/bart/create.c index dccfa3795b..529b625033 100644 --- a/usr/src/cmd/bart/create.c +++ b/usr/src/cmd/bart/create.c @@ -241,16 +241,6 @@ create_manifest_rule(char *reloc_root, FILE *rule_fp) for (root = get_first_subtree(); root != NULL; root = get_next_subtree(root)) { - /* - * This subtree has already been traversed by a - * previous stanza, i.e. this rule is a subset of a - * previous rule. - * - * Subtree has already been handled so move on! - */ - if (root->traversed) - continue; - /* * Check to see if this subtree should have contents * checking turned on or off. @@ -273,7 +263,6 @@ create_manifest_rule(char *reloc_root, FILE *rule_fp) */ subtree_root = root; (void) nftw64(root->subtree, &walker, 20, FTW_PHYS); - root->traversed = B_TRUE; /* * Ugly but necessary: @@ -340,7 +329,7 @@ output_manifest(void) * Also, make sure the output is unique, since a given file may be * included by several stanzas. */ - if (execle("/usr/bin/sort", "sort", NULL, env) < 0) { + if (execle("/usr/bin/sort", "sort", "-u", NULL, env) < 0) { perror(""); exit(FATAL_EXIT); } @@ -375,19 +364,6 @@ walker(const char *name, const struct stat64 *sp, int type, struct FTW *ftwx) case FTW_NS: /* unstatable file */ break; case FTW_D: /* enter directory */ - - /* - * Check to see if any subsequent rules are a subset - * of this rule; if they are, then mark them as - * "traversed". - */ - rule = subtree_root->next; - while (rule != NULL) { - if (strcmp(name, rule->subtree) == 0) - rule->traversed = B_TRUE; - - rule = rule->next; - } dir_flag = B_TRUE; ret = statvfs(name, &path_vfs); if (ret < 0) -- cgit v1.2.3