From 3edd4a24afe295eaf4b811a265318338b6690af2 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Thu, 2 Feb 2012 17:59:46 +0100 Subject: [PATCH] update_walk: use directory_make_child() --- src/update_walk.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/update_walk.c b/src/update_walk.c index e5eedc025..1d7f89c49 100644 --- a/src/update_walk.c +++ b/src/update_walk.c @@ -344,11 +344,8 @@ update_archive_tree(struct directory *directory, char *name) if (tmp) { *tmp = 0; //add dir is not there already - if ((subdir = directory_get_child(directory, name)) == NULL) { - //create new directory - subdir = directory_new_child(directory, name); - subdir->device = DEVICE_INARCHIVE; - } + subdir = directory_make_child(directory, name); + subdir->device = DEVICE_INARCHIVE; //create directories first update_archive_tree(subdir, tmp+1); } else {