aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--unpack/restore_fstree.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/unpack/restore_fstree.c b/unpack/restore_fstree.c
index ab10f5d..455e604 100644
--- a/unpack/restore_fstree.c
+++ b/unpack/restore_fstree.c
@@ -3,6 +3,7 @@
static int create_node(tree_node_t *n, data_reader_t *data, int flags)
{
+ tree_node_t *c;
char *name;
int fd;
@@ -23,8 +24,8 @@ static int create_node(tree_node_t *n, data_reader_t *data, int flags)
if (pushd(n->name))
return -1;
- for (n = n->data.dir->children; n != NULL; n = n->next) {
- if (create_node(n, data, flags))
+ for (c = n->data.dir->children; c != NULL; c = c->next) {
+ if (create_node(c, data, flags))
return -1;
}