static void rename_files(const struct adjusted *adj)
{
while (adj) {
- if (rename(adj->tmpfile, adj->file) != 0)
+ if (!move_file(adj->tmpfile, adj->file))
warn("Could not rename over '%s', we're in trouble",
adj->file);
adj = adj->next;
verbose("Adjusting %s\n", dir);
verbose_indent();
- for (deps = get_deps(parent, parent, talloc_basename(parent, dir),
- false);
- *deps; deps++) {
+ for (deps = get_deps(parent, dir, false, NULL); *deps; deps++) {
char *depdir;
struct adjusted *adj = NULL;
struct replace *repl;
if (access(info, R_OK) != 0)
continue;
- for (deps = get_deps(*file, talloc_dirname(*file, *file),
- talloc_basename(*file, *file), false);
+ for (deps = get_deps(*file, *file, false, NULL);
*deps; deps++) {
if (!strstarts(*deps, "ccan/"))
continue;