X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2Fnames.c;h=d65b04f6de5ba28243a9c112e3f28132e4b3fefe;hb=30873dbd970c9f8e139009a7a78ba8855a46c41b;hp=03eece6655a44b629ab25ec99ee0008548e53206;hpb=85cf996677770c517b4b6c138155c79d7c86b28f;p=chaz%2Ftar diff --git a/src/names.c b/src/names.c index 03eece6..d65b04f 100644 --- a/src/names.c +++ b/src/names.c @@ -1,7 +1,7 @@ /* Various processing of names. Copyright (C) 1988, 1992, 1994, 1996, 1997, 1998, 1999, 2000, 2001, - 2003, 2004, 2005 Free Software Foundation, Inc. + 2003, 2004, 2005, 2006 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the @@ -430,7 +430,7 @@ addname (char const *string, int change_dir) name->change_dir = change_dir; name->dir_contents = 0; name->explicit = 1; - + if (string && is_pattern (string)) { name->regexp = 1; @@ -713,7 +713,7 @@ add_hierarchy_to_namelist (struct name *name, dev_t device) if (*string == 'D') { struct name *np; - + if (allocated_length <= name_length + string_length) { do @@ -787,11 +787,19 @@ collect_and_sort_names (void) for (name = namelist; name; name = name->next) name->found_count = 0; + + if (listed_incremental_option) + { + for (name = namelist; name && name->fake; name++) + ; + if (name) + name->dir_contents = append_incremental_renames (name->dir_contents); + } } /* This is like name_match, except that 1. It returns a pointer to the name it matched, and doesn't set FOUND - in structure. The caller will have to do that if it wants to. + in structure. The caller will have to do that if it wants to. 2. If the namelist is empty, it returns null, unlike name_match, which returns TRUE. 3. The second argument (EXACT) controls matching algorithm. If it