From 5b93cb4cdc2c0f1b97a5617a09292bf3be4f69f6 Mon Sep 17 00:00:00 2001 From: Vreixo Formoso Date: Tue, 18 Dec 2007 10:54:09 +0100 Subject: [PATCH] Fix bug, root refcount must be initialized to 1. --- src/node.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/node.c b/src/node.c index d38294c..44f27e0 100644 --- a/src/node.c +++ b/src/node.c @@ -578,6 +578,7 @@ int iso_node_new_root(IsoDir **root) if (dir == NULL) { return ISO_MEM_ERROR; } + dir->node.refcount = 1; dir->node.type = LIBISO_DIR; dir->node.atime = dir->node.ctime = dir->node.mtime = time(NULL); dir->node.mode = S_IFDIR | 0555;